Sie sind auf Seite 1von 2

VB.

NET TUTORIAL
1. What are the different data types supported by Visual Basic? How they can be
declared? Also mention their uses.
2. Explain the properties and various methods used to manipulate list box control. How
indexing can be done with a list box control?
3. Write an event procedure to count the number of positive numbers, negative
numbers and zeroes in a given list of 10 numbers that are given as input. Also, design
the layout for an interactive front end with appropriate controls.
4. Write an event procedure to find the sum of the squares of "n" natural numbers.
Design proper layout for front-end interface.

5. Write an application that contains four command buttons. The command buttons
should be blue and have boldfaced, italicized captions that read Change Color,
Change Bold, Change Height, and Change Width. When the user clicks one of the
command buttons, the appropriate property should change inside the Click() event
procedure. Use a Select Case statement to determine which property should change
based on the event procedure's Index argument.

6. Create the equivalent of a four-function calculator. The program should request the
user to enter a number, an operator and another number. It should then carry out at
the specified arithmetical operation: addition, subtraction, multiplication or dividing
the 2 number. (It should use a switch statement to select the operator). Finally it
should display result.
When its finishes the calculation, the program should ask if the user want to another
calculation. The response can yes or no.
7. Given an interface as below write code for designing the interface and for four
buttons :- Calculate, Clear Sale, Print and Exit. Calculation are done as
Ext. Price = Quantity* Price,
Calculate discount based on quantity as no discount for quantity less than 5. if
quantity is 5 10 than 10% discount, if quantity is above 10 and less than 50 than 20
% discount. If quantity exceeds 50 than 35 % discount.
Total amount = Ext Price Discount.
Clear Sale clears all the text boxes.
Print Prints all textboxes. Exit Exit the application


8. Write sectional codes for the following:
a) Take a Command Button captioned as Order, a List Box which will display Restaurant
menus. Display the selected items in Message Box when Order Button is clicked.
b) Take a Text Box, Command Button, and three Option Buttons to select a course from
MCM / DCM / PGDCA. Display selected course in the Text Box when Command
Button is clicked.

Das könnte Ihnen auch gefallen