O'Reilly logo

Visual Basic 2005 for Programmers: Deitel Developer Series, Second Edition by Harvey M. Deitel - Deitel & Associates, Inc., Paul J. Deitel - Deitel & Associates, Inc.

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

3.2. Displaying a Line of Text

We begin by considering a simple program (Fig. 3.1) that displays a line of text. When this program runs, its output appears in a Command Prompt window. We show such output in a blue box following the program listing. You will see what a Command Prompt window looks like later in this section, when we explain the process of creating a console application.

Figure 3.1. Simple Visual Basic program.
					1
					' Fig. 3.1: Welcome1.vb
					2
					' Simple Visual Basic program.
					3
					4
					Module FirstWelcome
5
					6
					Sub Main()                                      
					7
					
					
					8
					   Console.WriteLine("Welcome to Visual Basic!")
					9
					
					
					10
					End Sub
						' Main
					
					11
					12
					End Module
					' FirstWelcome
				
Welcome to Visual Basic!

Analyzing the Program

This program illustrates several important Visual Basic features. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required