PROGRAMMING III
PROGRAMMING III
QUESTION 1
QUESTION 2
ii. List two common controls found in the Visual Basic Toolbox (4 Marks)
iii. What is the purpose of the 'Button' control in Visual Basic? (4 Marks)
iv. Describe the use of the 'TextBox' control in Visual Basic (4 Marks)
QUESTION 3
QUESTION 4
Write a Visual Basic code snippet that calculates the sum of two numbers entered by the user in
TextBox controls and displays the result in a Label control
Provide a code example that demonstrates how to calculate the sum of two numbers entered by the user
in TextBox controls and display the result in a Label control. (10 Marks)
Develop a Temperature Converter Application Task: Create an application in Visual Basic that
converts temperatures between Celsius and Fahrenheit.
Instructions:
o Add TextBox controls for entering the temperature value.
o Add RadioButton controls to select the conversion direction (Celsius to Fahrenheit or
Fahrenheit to Celsius).
o Add a Button to perform the conversion.
o Add a Label to display the converted temperature.
Write the code to perform the conversion based on the selected direction (10 Marks)
QUESTION 5
Task: Develop a student grade calculator in Visual Basic that calculates the average grade and
determines the grade letter.
Instructions:
o Add TextBox controls for entering grades.
o Add a Button to calculate the average grade.
o Add a Label to display the average grade and grade letter.
o Write the code to perform the calculations and display the results. (10 Marks)
o
Task: Create a currency converter application in Visual Basic that converts amounts between
different currencies.
Instructions:
o Add TextBox controls for entering the amount to be converted.
o Add ComboBox controls for selecting the source and target currencies.
o Add a Button to perform the conversion.
o Add a Label to display the converted amount.
o Write the code to perform the conversion based on predefined exchange rates. (10
Marks)