Welcome to Scribd, the world's digital library. Read, publish, and share books and documents. See more
Download
Standard view
Full view
of .
Look up keyword
Like this
3Activity
0 of .
Results for:
No results containing your search query
P. 1
Vb.net Practical No

Vb.net Practical No

Ratings: (0)|Views: 130 |Likes:
Published by Nouman M Durrani
Nouman M Durrani Teaching Notes of VB.Net, Linux and SQL Server
Nouman M Durrani Teaching Notes of VB.Net, Linux and SQL Server

More info:

Published by: Nouman M Durrani on Jan 19, 2011
Copyright:Attribution Non-commercial

Availability:

Read on Scribd mobile: iPhone, iPad and Android.
download as DOC, PDF, TXT or read online from Scribd
See more
See less

03/13/2013

pdf

text

original

 
Microsoft VB.Netand ASP.Net
1
 
Practical No. 01
Enumeration
: Enumeration is a related set of constants. They are used whenworking with many constants of the same type. It's declared with the Enum keyword.Output of above code is the image below:
Imports System.ConsoleModule Module1Enum SeasonsSummer = 1Winter = 2Spring = 3Autumn = 4End EnumSub Main()Write("Summer is the" & Seasons.Summer & "season")End SubEnd Module
2
 
Practical No. 02
If....Else statement
If conditional expression is one of the most useful control structures which allows usto execute a expression if a condition is true and execute a different expression if it isFalse. The syntax looks like this:
If condition Then[statements]Else If condition Then[statements]--Else[statements]End If
If the condition is true, the statements following the Then keyword will be executed,else, the statements following the ElseIf will be checked and if true, will be executed,else, the statements in the else part will be executed.
Imports System.ConsoleModule Module1Sub Main()Dim i As IntegerWriteLine("Enter an integer, 1 or 2 or 3")i = Val(ReadLine())'ReadLine() method is used to read from consoleIf i = 1 ThenWriteLine("One")ElseIf i = 2 ThenWriteLine("Two")ElseIf i = 3 ThenWriteLine("Three")ElseWriteLine("Number not 1,2,3")End IfEnd SubEnd Module
3

You're Reading a Free Preview

Download
scribd
/*********** DO NOT ALTER ANYTHING BELOW THIS LINE ! ************/ var s_code=s.t();if(s_code)document.write(s_code)//-->