BIT 4202 ADVANCED APPLICATION PROGRAMMING KCA Past Paper

UNIVERSITY EXAMINATIONS: 2012/2013
THIRD YEAR EXAMINATION FOR THE BACHELOR OF
SCIENCE IN INFORMATION TECHNOLOGY
BIT 4202 ADVANCED APPLICATION PROGRAMMING
DATE: DECEMBER, 2012 TIME: 2 HOURS
INSTRUCTIONS: Answer Question ONE and any other TWO

QUESTION ONE
a) Describe three major roles played by Ado.net in application development today
(6 Marks)
b) Explain how the escape key on the keyboard can be mapped to the cancel button on
a form and the enter key is mapped o the ok button (4 Marks)
c) Explain the following references to array elements: (4 Marks)
AmountDecimal(3)
StatesString(6)
d) Describe the two ways used to fill a List control in VB and explain situations where
each way is best suited. (5 Marks)
e) i. Define a MenuStrip control as used in VB (3 Marks)
ii. Explain two ways used to display data from a database on a VB form.
(4 Marks)
iii. Menus often have hot keys. Describe how you can add a hot key to a menu
in VB.net using an example to illustrate. (4 Marks)
QUESTION TWO
a) Describe the steps followed when setting up a connection to a database or other
type of data source using VB.NET (6 Marks)
b) Describe four different types of ADO.NET connections to databases across
networks (8 Marks)
c) Visual basic provides three controls to enable an application user to select from a
list of items: List and describe these controls (6 Marks)
QUESTION THREE
a) Write a programme that does the following:
1. Asks users to enter a number between 10 and 20.
2. The number will be entered into the Textbox.
3. When the Button is clicked, your Visual Basic code will check the number
entered in the Textbox.
4. If it is between 10 and 20, then a message will be displayed.
5. The message box will display the number from the Textbox.
6. If the number entered is not between 10 and 20 then the user will be invited to try
again, and whatever was entered in the Textbox will be erased
(10 Marks)
b) Add a Combo box and another button to your form. Create a list of items for your
Combo Box. The list of items in your Combo box can be anything you like – pop
groups, football teams, favourite foods, anything of your choice. Then try the
following:
Use a select case statement to test what a user has chosen from your dropdown list. Give the user a suitable message when the button was clicked.
(10 Marks)
QUESTION FOUR
a) Describe the general format of the Block If statement as used in VB (4 Marks)
b) State and explain four rules to be followed when using the block if statement in
VB (8 Marks)
c) Draw a flow chart to represent the If Statement in VB (6 Marks)
d) Using examples explain the term logical operators (2 Marks)
QUESTION FIVE
a) Describe the four levels of variable scope in VB (8 Marks)
b) Explain the use of the following common VB controls (12 Marks)
i. TextBox
ii. MaskedTextBox Control
iii. A GroupBox control
iv. RichTextBox Control
v. CheckBox contro
vi. PictureBox Control

(Visited 98 times, 1 visits today)
Share this:

Written by