Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Pause a dos screen while debugging 2

Status
Not open for further replies.

Nademic

Programmer
Mar 25, 2008
18
0
0
CA
Hi all,

I have build a console app and when I debug it the console window flashes and goes away. Is their a way to stop this screen from disappearing? Thanks in advance.
 
Something like this maybe:

Code:
Imports System.Console
Module Module1

	Sub Main()

		Dim x As Integer
		Dim y As Integer
		Write("Enter a number: ")
		x = Convert.ToInt32(ReadLine())
		Write("Enter another number: ")
		y = Convert.ToInt32(ReadLine())
		WriteLine(x.ToString + " * " + y.ToString + " = " + (x * y).ToString)
		'Don't let the Console window close automatically - wait until the user presses enter
		ReadLine()

	End Sub

End Module


Hope this helps.

[vampire][bat]
 
Ok I get it. The readline procedure stops the window because it's expecting some entry followed by the enter key. Thanks alot, star for you my friend. :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top