Click here to Skip to main content
15,890,512 members
Home / Discussions / Visual Basic
   

Visual Basic

 
Question[Message Deleted] Pin
εїзεїзεїз5-Feb-09 2:07
εїзεїзεїз5-Feb-09 2:07 
AnswerRe: Grid View Control Pin
Henry Minute5-Feb-09 9:16
Henry Minute5-Feb-09 9:16 
QuestionWhere to put try / catch blocks when dealing with classes Pin
maxnuggets5-Feb-09 0:55
maxnuggets5-Feb-09 0:55 
AnswerRe: Where to put try / catch blocks when dealing with classes Pin
Johan Hakkesteegt5-Feb-09 2:09
Johan Hakkesteegt5-Feb-09 2:09 
GeneralRe: Where to put try / catch blocks when dealing with classes Pin
maxnuggets5-Feb-09 2:22
maxnuggets5-Feb-09 2:22 
GeneralRe: Where to put try / catch blocks when dealing with classes Pin
Johan Hakkesteegt5-Feb-09 3:04
Johan Hakkesteegt5-Feb-09 3:04 
AnswerRe: Where to put try / catch blocks when dealing with classes Pin
riced5-Feb-09 4:43
riced5-Feb-09 4:43 
GeneralRe: Where to put try / catch blocks when dealing with classes Pin
supercat95-Feb-09 6:28
supercat95-Feb-09 6:28 
Can MyClass do anything meaningful to recover from the exception? If it can then it probably should handle it, if not then don't catch it. (You might want to catch it so you can add additional info to the message and then re-throw the exception.)

Another question to ask is whether the caller is more likely to want to keep on with what it's doing despite the exception, or whether it will want to break out of any loop it's in. Personally I would think that in many situations the right approach would be to have routines take an error-function delegate which could throw an exception, silently swallow the error, or do something else. The try/do pattern isn't bad, but it provides no mechanism for distinguishing different types of failures nor for resolving them proactively.

Also, note that most of the time when you catch an exception and rethrow it, you should either use the word "throw" without an argument (if you don't want to change the exception type), or you should make a new exception that contains the original one as an InnerException.
QuestionModifying a window service Pin
sohaib_a4-Feb-09 22:58
sohaib_a4-Feb-09 22:58 
AnswerRe: Modifying a window service Pin
Dave Kreskowiak5-Feb-09 2:23
mveDave Kreskowiak5-Feb-09 2:23 
Questionvb express list box Pin
steve moorley4-Feb-09 22:49
steve moorley4-Feb-09 22:49 
AnswerRe: vb express list box Pin
Rupesh Kumar Swami4-Feb-09 22:57
Rupesh Kumar Swami4-Feb-09 22:57 
Questioncompiling what was compiled before Pin
Member 42169604-Feb-09 22:36
Member 42169604-Feb-09 22:36 
AnswerRe: compiling what was compiled before Pin
Alan N5-Feb-09 0:25
Alan N5-Feb-09 0:25 
GeneralRe: compiling what was compiled before Pin
Member 42169605-Feb-09 0:40
Member 42169605-Feb-09 0:40 
GeneralRe: compiling what was compiled before Pin
Dave Kreskowiak5-Feb-09 2:20
mveDave Kreskowiak5-Feb-09 2:20 
GeneralRe: compiling what was compiled before Pin
Member 42169605-Feb-09 4:58
Member 42169605-Feb-09 4:58 
GeneralRe: compiling what was compiled before Pin
Dave Kreskowiak5-Feb-09 5:31
mveDave Kreskowiak5-Feb-09 5:31 
GeneralRe: compiling what was compiled before Pin
EliottA5-Feb-09 6:06
EliottA5-Feb-09 6:06 
GeneralRe: compiling what was compiled before Pin
Member 42169605-Feb-09 20:52
Member 42169605-Feb-09 20:52 
GeneralRe: compiling what was compiled before Pin
Dave Kreskowiak6-Feb-09 14:17
mveDave Kreskowiak6-Feb-09 14:17 
GeneralRe: compiling what was compiled before Pin
Member 42169607-Feb-09 0:29
Member 42169607-Feb-09 0:29 
AnswerRe: compiling what was compiled before Pin
Jay Royall5-Feb-09 0:30
Jay Royall5-Feb-09 0:30 
AnswerRe: compiling what was compiled before Pin
EliottA5-Feb-09 5:07
EliottA5-Feb-09 5:07 
QuestionI need events of Datagridcomboboxcolumn Pin
A.gomathi nayagam4-Feb-09 18:36
A.gomathi nayagam4-Feb-09 18:36 

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.