Question return code

rrrprogrammer

Member
Joined
Aug 15, 2008
Messages
7
Programming Experience
10+
what is standard way of using return codes in VB.NET?

Are we still using 1(success) and 0(failure) ?

or are we using Boolean as return code?

When do you use a return code?
 
From Process.ExitCode help:
Developers usually indicate a successful exit by an ExitCode value of zero, and designate errors by nonzero values that the calling method can use to identify the cause of an abnormal process termination. It is not necessary to follow these guidelines, but they are the convention.
Exit codes are normally used only for applications that are called by other applications in automation fashion, for example console applications, or by windows services. You can set Environment.ExitCode if you like.
 
Back
Top