Click here to Skip to main content
15,912,282 members
Home / Discussions / C#
   

C#

 
AnswerRe: Nested try/catch blocks Pin
Christian Graus18-Jun-09 22:41
protectorChristian Graus18-Jun-09 22:41 
It won't invalidate anything. You can just put an (if conn != null) type block at the start of the second try/catch, and then your finally block will work fine. Indeed, command.ExecuteNonQuery would just force the catch and finally, if conn was null. I'm also not sure why conn couldn't be in the existing try block, just declare trans outside it, and begin it, inside.

Christian Graus

Driven to the arms of OSX by Vista.

"! i don't exactly like or do programming and it only gives me a headache." - spotted in VB forums.

I can do things with my brain that I can't even google. I can flex the front part of my brain instantly anytime I want. It can be exhausting and it even causes me vision problems for some reason. - CaptainSeeSharp

GeneralRe: Nested try/catch blocks Pin
Helfdane18-Jun-09 22:45
Helfdane18-Jun-09 22:45 
JokeRe: Nested try/catch blocks Pin
DaveyM6918-Jun-09 22:49
professionalDaveyM6918-Jun-09 22:49 
GeneralRe: Nested try/catch blocks Pin
Helfdane18-Jun-09 22:53
Helfdane18-Jun-09 22:53 
GeneralOT Pin
Vikram A Punathambekar18-Jun-09 23:59
Vikram A Punathambekar18-Jun-09 23:59 
AnswerRe: Nested try/catch blocks Pin
Nagy Vilmos18-Jun-09 22:58
professionalNagy Vilmos18-Jun-09 22:58 
GeneralRe: Nested try/catch blocks Pin
Helfdane18-Jun-09 23:16
Helfdane18-Jun-09 23:16 
GeneralRe: Nested try/catch blocks Pin
Nagy Vilmos19-Jun-09 0:58
professionalNagy Vilmos19-Jun-09 0:58 
GeneralRe: Nested try/catch blocks Pin
PandemoniumPasha18-Jun-09 23:29
PandemoniumPasha18-Jun-09 23:29 
GeneralRe: Nested try/catch blocks Pin
Nagy Vilmos19-Jun-09 0:55
professionalNagy Vilmos19-Jun-09 0:55 
AnswerRe: Nested try/catch blocks Pin
PIEBALDconsult19-Jun-09 5:30
mvePIEBALDconsult19-Jun-09 5:30 
Questionto display image from listview Pin
deleepkv18-Jun-09 22:15
deleepkv18-Jun-09 22:15 
AnswerRe: to display image from listview Pin
Christian Graus18-Jun-09 22:43
protectorChristian Graus18-Jun-09 22:43 
GeneralRe: to display image from listview Pin
deleepkv18-Jun-09 23:57
deleepkv18-Jun-09 23:57 
Questionhow to Include Graph in C# windows Application Pin
Mads11518-Jun-09 20:49
Mads11518-Jun-09 20:49 
AnswerRe: how to Include Graph in C# windows Application Pin
stancrm18-Jun-09 21:03
stancrm18-Jun-09 21:03 
GeneralRe: how to Include Graph in C# windows Application Pin
Mads11518-Jun-09 21:31
Mads11518-Jun-09 21:31 
Questionis there a way to print pdf on different printers without making the alignment run out, using iReport? Pin
daffy_200318-Jun-09 20:31
daffy_200318-Jun-09 20:31 
Questionsqlbulkcopy issues Pin
havejeet18-Jun-09 20:17
havejeet18-Jun-09 20:17 
AnswerRe: sqlbulkcopy issues Pin
Mycroft Holmes18-Jun-09 22:02
professionalMycroft Holmes18-Jun-09 22:02 
QuestionHow is it possible to access private members of a class becoz the property of the field is made protected internal ? Pin
Member 397434718-Jun-09 20:05
Member 397434718-Jun-09 20:05 
AnswerRe: How is it possible to access private members of a class becoz the property of the field is made protected internal ? Pin
Christian Graus18-Jun-09 20:32
protectorChristian Graus18-Jun-09 20:32 
AnswerRe: How is it possible to access private members of a class becoz the property of the field is made protected internal ? Pin
Vikram A Punathambekar18-Jun-09 20:34
Vikram A Punathambekar18-Jun-09 20:34 
GeneralRe: How is it possible to access private members of a class becoz the property of the field is made protected internal ? Pin
Christian Graus18-Jun-09 21:39
protectorChristian Graus18-Jun-09 21:39 
GeneralRe: How is it possible to access private members of a class becoz the property of the field is made protected internal ? Pin
Vikram A Punathambekar19-Jun-09 0:01
Vikram A Punathambekar19-Jun-09 0:01 

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.