|
StringWriter and HtmlTextWriter are disposable. It is a good practice to wrap inside using block when working with disposable objects to avoid resource leaks.
Best wishes,
Navaneeth
|
|
|
|
|
Yes .. This is the responsibility of the user I guess..
Anyways Thanks for your input.. .
|
|
|
|
|
N a v a n e e t h wrote: StringWriter and HtmlTextWriter are disposable. It is a good practice to wrap inside using block when working with disposable objects to avoid resource leaks.
Abhijit Jana | Codeproject MVP
Web Site : abhijitjana.net
Don't forget to click "Good Answer" on the post(s) that helped you.
|
|
|
|
|
|
Hi everyone. Is it possible in ASP.net 1.1 to execute Sql Server 2005 SSIS package or dtsx package with C#. I say this because the namespace used for this is Microsoft.SqlServer.Dts.Runtime and this is not showing when I'm trying to add new reference in ASP.net 1.1. Please help.
|
|
|
|
|
Respected,
why this is happen when i open
code project site the content page display -- Unable to load messages due to high load. Please try again --
message.
Thanks.
|
|
|
|
|
What? ?
You mean this is happening in Codeproject site.
If so, this is not the right place to talk about this. Place your query in Site Suggession section.
|
|
|
|
|
Hi All,
In our website, we have to provide activating new users account.
i.e.,In a website if any new user registers we will send the mail right that is ok but we have to send a mail to activate the useraccount.Can any one please tell how to do that ASAP?
thanks in advance
|
|
|
|
|
getaccessyr wrote: how to do that ASAP?
Are you using forms authentication..!If yes..!you can use Guid key ..!
LatestArticle :Log4Net
Why Do Some People Forget To Mark as Answer .If It Helps.
|
|
|
|
|
What does it mean?
You have to make your own logic. Just send a mail with a link that has the unique identification in its querystring. Now when user activates the link place the active boolean field in the database to true.
Hey this could be done 1000 ways.. So better you make your own logic.
|
|
|
|
|
I've got GridView control consisted of a template and a bound field.
I defined either autogenerated edit buttons, or added the one in item template.
I also added edit template for GridView control.
When I click that edit button as the view is populated with 1 record to edit it, the rowediting evet fires in which I set GridView.EditIndex = e.NewEditIndex
Page post back happen, but GridView does not change that row into edit mode.
Nither item template to edit template nor bound field???
Чесноков
|
|
|
|
|
hi,
you need to re bind gridview control with in RowEditing event
as
GridHeading.EditIndex = e.NewEditIndex;
BindGrid();
-----
abbas
|
|
|
|
|
thank you, I forgot ASP.NET is stateless after a lot of win app programming. It reminded me
Чесноков
|
|
|
|
|
Hi All,
I am implementing 3 tier architecture
From the UI
in UI
MySqlDataReader reader = businessLogic.GetRoles();
ddRole.DataSource = reader;
ddRole.DataBind();
In DAl
public MySqlDataReader ExecuteReader(String query)
{
MySqlConnection con = new MySqlConnection((connectionString));
MySqlCommand cmd = new MySqlCommand(query, con);
con.Open();
MySqlDataReader reader =cmd.ExecuteReader();
con.Close();
return reader;
}
but when i close the connection reader also get close so that it returns null
how can i solve this probs
|
|
|
|
|
This is an expected behavior. When you close the connection, everything is closed with it.
If you really want to create the connection, the command and the reader in the same method, to then return the reader, I think you should implement a wrapper class that also contains the connection.
For example:
The MyReader class implements dispose as:
connection.Close();
And implements the IDataReader interface, making everycall redirect to
[return ]reader.Method([parameters]);
This way, users will still see a IDataReader returned, but when closing the reader the connection (command and reader) are closed.
Another way, more simple, is to return an struct that contains Connection, Command and Reader public acessible... so the calling method can use the reader, and at the end it is responsible for calling Connection.Close().
|
|
|
|
|
To summarize :
SqlDataReader required a open connection to read data.
|
|
|
|
|
Hi all,
how to display large data ( like 1 lac records) to crystal reports in asp.net
I am getting this error when i am tried like this :
Application service unavaiable .
The web application you are attempting to access on this web server is currently unavaiable .please hit the refersh button in ur web browser to retry your request.
Please find a solutions for this .
Thanks
Murali
|
|
|
|
|
Yes.. Why do you need to show this in browser. Writing excessive data in browser will eat up all the memory of the process associated with the browser. And this leads to hang your browser.
I recommend to do pagination do overcome this situation.
|
|
|
|
|
among following who cant host a .net application
IIS,InterNet Explorer,ASp.net and windows shell
vikas da
|
|
|
|
|
This sounds like an interview question
AFAIK, all four can host .NET apps (I'm doubtful about Windows Shell though)
|
|
|
|
|
THats right am not sure why they asked...
vikas da
|
|
|
|
|
Actually IIS is the main hosting environment for web applications.
Internet Explorer is the client for the IIS (which is not obviously the host, but client), ASP.NET is the technology, and Windows Shell is the platform.
so if this is your interview question, you need to pick only IIS.
|
|
|
|
|
Respected Sir
I Need Help From U
I want a Cms Editor Which Supports Asp.net And Also Supports Multi Lauguages Like English,Hindi,...
And Also Open Source Code Free Downloadable Software Can U Give Me Reply Please
From
Laxman
|
|
|
|
|
Hey, this could go one of two ways. I want a rich text editor for my website, the information typed into the text editor will be saved to an sql server database under either char or varchar format that supports up to 8000 characters per field. I want it to save as html code. This content will then be pulled from the database to be displayed in a label. Now my question is, what is a good C# html rich text editor (must be free) OR how can I make one for C# (preferred).
Thanks in advance
Abbas
|
|
|
|
|