Click here to Skip to main content
15,892,809 members
Home / Discussions / ASP.NET
   

ASP.NET

 
QuestionActivate account in a site Pin
getaccessyr13-Nov-09 0:49
getaccessyr13-Nov-09 0:49 
AnswerRe: Activate account in a site [modified] Pin
sashidhar13-Nov-09 1:11
sashidhar13-Nov-09 1:11 
AnswerRe: Activate account in a site Pin
Abhishek Sur13-Nov-09 4:39
professionalAbhishek Sur13-Nov-09 4:39 
QuestionHow to put GridView control into edit mode Pin
Chesnokov Yuriy13-Nov-09 0:40
professionalChesnokov Yuriy13-Nov-09 0:40 
AnswerRe: How to put GridView control into edit mode Pin
Abbas_here13-Nov-09 1:25
Abbas_here13-Nov-09 1:25 
GeneralRe: How to put GridView control into edit mode Pin
Chesnokov Yuriy13-Nov-09 2:20
professionalChesnokov Yuriy13-Nov-09 2:20 
QuestionSqlDataReader Problem Pin
Amit Patel198513-Nov-09 0:18
Amit Patel198513-Nov-09 0:18 
AnswerRe: SqlDataReader Problem Pin
Paulo Zemek13-Nov-09 0:33
mvaPaulo Zemek13-Nov-09 0:33 
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().
AnswerRe: SqlDataReader Problem Pin
Abhishek Sur13-Nov-09 4:33
professionalAbhishek Sur13-Nov-09 4:33 
Questionproblem to display large data ( like 1 lac records) to crystal reports in asp.net Pin
ballameharmurali12-Nov-09 23:09
ballameharmurali12-Nov-09 23:09 
AnswerRe: problem to display large data ( like 1 lac records) to crystal reports in asp.net Pin
Abhishek Sur12-Nov-09 23:39
professionalAbhishek Sur12-Nov-09 23:39 
QuestionHosting a .net application Pin
tasumisra12-Nov-09 22:56
tasumisra12-Nov-09 22:56 
AnswerRe: Hosting a .net application Pin
Shameel12-Nov-09 23:34
professionalShameel12-Nov-09 23:34 
GeneralRe: Hosting a .net application Pin
tasumisra12-Nov-09 23:39
tasumisra12-Nov-09 23:39 
AnswerRe: Hosting a .net application Pin
Abhishek Sur13-Nov-09 4:27
professionalAbhishek Sur13-Nov-09 4:27 
QuestionWhat is the Cms Editor which Supports Asp.net2.0 and Supports Multi lauguages like English,Hindi,Telugu...........Etc ? Pin
axman_podili@yahoo.co.in12-Nov-09 22:52
axman_podili@yahoo.co.in12-Nov-09 22:52 
QuestionRich text editor for html code Pin
Abbas_here12-Nov-09 22:50
Abbas_here12-Nov-09 22:50 
AnswerRe: Rich text editor for html code Pin
Petr Pechovic12-Nov-09 23:24
professionalPetr Pechovic12-Nov-09 23:24 
GeneralRe: Rich text editor for html code Pin
Abbas_here12-Nov-09 23:32
Abbas_here12-Nov-09 23:32 
QuestionCustom control inside UpdatePanel throws warning Pin
miniThomas12-Nov-09 21:55
miniThomas12-Nov-09 21:55 
AnswerRe: Custom control inside UpdatePanel throws warning Pin
Abhijit Jana13-Nov-09 7:21
professionalAbhijit Jana13-Nov-09 7:21 
GeneralRe: Custom control inside UpdatePanel throws warning Pin
miniThomas16-Nov-09 1:35
miniThomas16-Nov-09 1:35 
QuestionSql Helper Pin
Amit Patel198512-Nov-09 21:18
Amit Patel198512-Nov-09 21:18 
AnswerRe: Sql Helper Pin
Abhishek Sur12-Nov-09 22:38
professionalAbhishek Sur12-Nov-09 22:38 
AnswerRe: Sql Helper Pin
Abhijit Jana13-Nov-09 7:25
professionalAbhijit Jana13-Nov-09 7:25 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.