Click here to Skip to main content
15,891,423 members
Home / Discussions / C#
   

C#

 
GeneralRe: visual C# 2005 exiting Pin
rockNroll19-Mar-08 13:03
rockNroll19-Mar-08 13:03 
GeneralRe: visual C# 2005 exiting Pin
xxmikexx19-Mar-08 13:04
xxmikexx19-Mar-08 13:04 
GeneralRe: visual C# 2005 exiting Pin
Not Active19-Mar-08 13:08
mentorNot Active19-Mar-08 13:08 
GeneralRe: visual C# 2005 exiting Pin
xxmikexx19-Mar-08 13:10
xxmikexx19-Mar-08 13:10 
GeneralRe: visual C# 2005 exiting Pin
rockNroll19-Mar-08 13:15
rockNroll19-Mar-08 13:15 
GeneralRe: visual C# 2005 exiting Pin
xxmikexx19-Mar-08 13:17
xxmikexx19-Mar-08 13:17 
GeneralRe: visual C# 2005 exiting Pin
MarkB77719-Mar-08 13:51
MarkB77719-Mar-08 13:51 
GeneralRe: visual C# 2005 exiting Pin
engsrini19-Mar-08 12:21
engsrini19-Mar-08 12:21 
the code which i posted can work in both console and windows.. dont confuse with Debug.Writeline satement, it is just used to print in Output Window.
ie.

<br />
private void button1_Click(object sender, EventArgs e)<br />
{<br />
int x = 5;<br />
if (x == 5)<br />
{<br />
Debug.WriteLine("more code to runs here1");<br />
Debug.WriteLine("more code to runs here2");<br />
if(done) <br />
return; // This will exit the funtion button1_Click<br />
else<br />
{<br />
Debug.WriteLine("more code to runs here3");<br />
Debug.WriteLine("more code to runs here4");<br />
Debug.WriteLine("more code to runs here5");<br />
}<br />
}<br />
Debug.WriteLine("more code to runs here6");<br />
Debug.WriteLine("more code to runs here7");<br />
Debug.WriteLine("more code to runs here8");<br />
<br />
}<br />


the return statement will exit from the funtion button1_Click.

Srini
GeneralRe: visual C# 2005 exiting Pin
xxmikexx19-Mar-08 12:28
xxmikexx19-Mar-08 12:28 
GeneralRe: visual C# 2005 exiting Pin
xxmikexx19-Mar-08 11:51
xxmikexx19-Mar-08 11:51 
Question[Message Deleted] Pin
123shailesh19-Mar-08 7:18
123shailesh19-Mar-08 7:18 
GeneralRe: Trouble Retrieving Coordinates Pin
Christian Graus19-Mar-08 10:28
protectorChristian Graus19-Mar-08 10:28 
GeneralSSO Pin
IWannaTalk19-Mar-08 6:24
IWannaTalk19-Mar-08 6:24 
GeneralRe: SSO Pin
IWannaTalk20-Mar-08 7:40
IWannaTalk20-Mar-08 7:40 
GeneralControlStyles.OptimizedDoubleBuffer increases my flicker problems Pin
poppabaggins19-Mar-08 6:16
poppabaggins19-Mar-08 6:16 
GeneralRe: ControlStyles.OptimizedDoubleBuffer increases my flicker problems Pin
mmikey719-Mar-08 7:12
mmikey719-Mar-08 7:12 
GeneralRe: ControlStyles.OptimizedDoubleBuffer increases my flicker problems Pin
poppabaggins19-Mar-08 11:31
poppabaggins19-Mar-08 11:31 
QuestionHow to encode an existing txt file? Pin
pcaeiro19-Mar-08 6:15
pcaeiro19-Mar-08 6:15 
GeneralRe: How to encode an existing txt file? Pin
Paul Conrad21-Mar-08 10:06
professionalPaul Conrad21-Mar-08 10:06 
GeneralRe: How to encode an existing txt file? Pin
pcaeiro22-Mar-08 5:26
pcaeiro22-Mar-08 5:26 
GeneralRe: How to encode an existing txt file? Pin
Paul Conrad22-Mar-08 5:37
professionalPaul Conrad22-Mar-08 5:37 
Generalhandlers or 4 sided handles Pin
netJP12L19-Mar-08 6:10
netJP12L19-Mar-08 6:10 
QuestionRe: handlers or 4 sided handles Pin
Krazy Programmer19-Mar-08 7:39
Krazy Programmer19-Mar-08 7:39 
GeneralRe: handlers or 4 sided handles Pin
netJP12L19-Mar-08 8:37
netJP12L19-Mar-08 8:37 
GeneralDateTime.AddDays(1) Issue Pin
Harvey Saayman19-Mar-08 6:10
Harvey Saayman19-Mar-08 6:10 

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.