Saturday, September 17, 2011

Use Do Loop to read user input

Module Module1

    Sub Main()
        Dim strInput As String

        Do
            Console.WriteLine("Please enter 'q' to quit...")
            strInput = Console.ReadLine()
            Console.WriteLine("You typed " & strInput)
        Loop While (strInput <> "q")
        Console.WriteLine("Quitting now.")
    End Sub

End Module

No comments:

Post a Comment

Explain the different parts that constitute ASP.NET application.

Content, program logic and configuration file constitute an ASP.NET application. Content files Content files include static text, images ...