Click here to Skip to main content
16,017,907 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Specified cast is not valid Pin
newbjohny5-Aug-06 6:23
newbjohny5-Aug-06 6:23 
GeneralRe: Specified cast is not valid Pin
Stephen McGuire5-Aug-06 6:32
Stephen McGuire5-Aug-06 6:32 
GeneralRe: Specified cast is not valid [modified] Pin
newbjohny5-Aug-06 6:45
newbjohny5-Aug-06 6:45 
GeneralRe: Specified cast is not valid Pin
Stephen McGuire5-Aug-06 6:56
Stephen McGuire5-Aug-06 6:56 
GeneralRe: Specified cast is not valid Pin
newbjohny5-Aug-06 7:02
newbjohny5-Aug-06 7:02 
GeneralRe: Specified cast is not valid Pin
Stephen McGuire5-Aug-06 7:06
Stephen McGuire5-Aug-06 7:06 
GeneralRe: Specified cast is not valid Pin
newbjohny5-Aug-06 7:13
newbjohny5-Aug-06 7:13 
GeneralRe: Specified cast is not valid Pin
Colin Angus Mackay5-Aug-06 5:36
Colin Angus Mackay5-Aug-06 5:36 
newbjohny wrote:
I have been taught this way at University so as not to crash out the program.


Your try/catch blocks here are being used for debugging purposes not to prevent the application from crashing. Using try/catch for debugging is a waste of time when there are better tools available.

Did your university not teach you how to set breakpoints and step through code and how to watch variables?

You need to find out the full stack trace of where the exception was thrown. By catching the exception and displaying only the message you've thrown all that information away - get rid of the try/catch and see where the application actaully crashes. When it does the Visual Studio debugger will show you exactly where the crash is (even if it is in code you did not write)

If you are missing a referrence your application is unlikely to compile on your home machine.


GeneralRe: Specified cast is not valid Pin
newbjohny5-Aug-06 5:53
newbjohny5-Aug-06 5:53 
GeneralRe: Specified cast is not valid Pin
Colin Angus Mackay5-Aug-06 5:59
Colin Angus Mackay5-Aug-06 5:59 
GeneralRe: Specified cast is not valid Pin
newbjohny5-Aug-06 6:16
newbjohny5-Aug-06 6:16 
AnswerRe: Specified cast is not valid [modified] Pin
Colin Angus Mackay5-Aug-06 6:03
Colin Angus Mackay5-Aug-06 6:03 
GeneralRe: Specified cast is not valid Pin
newbjohny5-Aug-06 6:19
newbjohny5-Aug-06 6:19 
GeneralRe: Specified cast is not valid Pin
Colin Angus Mackay5-Aug-06 10:05
Colin Angus Mackay5-Aug-06 10:05 
GeneralRe: Specified cast is not valid Pin
newbjohny5-Aug-06 10:36
newbjohny5-Aug-06 10:36 
AnswerRe: Specified cast is not valid [modified] Pin
mtone5-Aug-06 18:32
mtone5-Aug-06 18:32 
GeneralRe: Specified cast is not valid Pin
newbjohny5-Aug-06 23:41
newbjohny5-Aug-06 23:41 
AnswerRe: Specified cast is not valid Pin
newbjohny7-Aug-06 2:35
newbjohny7-Aug-06 2:35 
QuestionFind and replace Pin
Harold_Wishes5-Aug-06 4:21
Harold_Wishes5-Aug-06 4:21 
QuestionHow To make key events work within a datagrid Pin
rahulnair4-Aug-06 23:06
rahulnair4-Aug-06 23:06 
AnswerRe: How To make key events work within a datagrid Pin
Rey99995-Aug-06 1:08
Rey99995-Aug-06 1:08 
QuestionMulti Threading Pin
BorgPidgeon4-Aug-06 22:21
BorgPidgeon4-Aug-06 22:21 
QuestionConvert integer to time........ Pin
Nagraj Naik4-Aug-06 19:19
Nagraj Naik4-Aug-06 19:19 
AnswerRe: Convert integer to time........ Pin
militiaware5-Aug-06 1:36
militiaware5-Aug-06 1:36 
AnswerRe: Convert integer to time........ Pin
mtone7-Aug-06 17:46
mtone7-Aug-06 17:46 

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.