Practice high-yield Computer Science & IT MCQs on Visual Basic — Part 2 with worked academic solutions for PPSC, FPSC, CSS, PMS, NTS.
Questions
40
Difficulty Level
Exam-Level
Target Exams
PPSC, FPSC, CSS...
Estimated Time
48 mins
Exam-Level PPSC FPSC CSS PMS NTS
Verified for Commission Syllabus • Oct 14, 2026
40
Verified Practice Questions
Interactive test mode with detailed academic worked solutions
Live Progress|0/40 answered
✓0 correct
✗0 wrong
0% score
🎉 Set complete! All 40 questions answered.
Question 1 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
A . . . . . . . . allows you to select from a list of choices.
Correct Answer: Option A — Combo Box
Detailed Academic Explanation:
Combo Box is the correct answer to “A . . . . . . . . allows you to select from a list of choices.”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 2 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
What is the array of these statements? Dim intScores As Integer = {78, 83, 75, 90} Array.reverse (intScores)
Correct Answer: Option D — Compilation Error
Detailed Academic Explanation:
Compilation Error is the correct answer to “What is the array of these statements? Dim intScores As Integer = {78, 83, 75, 90} Array.reverse (intScores)”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 3 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
The select case statement ends with . . . . . . . .
Correct Answer: Option B — End Select clause
Detailed Academic Explanation:
End Select clause is the correct answer to “The select case statement ends with . . . . . . . .”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 4 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
Which of the following is used to display a message box in Visual Basic?
Correct Answer: Option A — MessageBox.Show
Detailed Academic Explanation:
MessageBox.Show is the correct answer to “Which of the following is used to display a message box in Visual Basic”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 5 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
What is the value of len in the following Visual Basic code? Dim strVB() As String = {"Example", "Visual Basic", "VB.Net", "Visual Studio"} Dim len As Integer len = strVB.Length()
Correct Answer: Option C — 4
Detailed Academic Explanation:
4 is the correct answer to “What is the value of len in the following Visual Basic code? Dim strVB() As String = {"Example", "Visual Basic", "VB.Net", "Visual Studio"} Dim len As Integer len = strVB.Length()”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 6 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
In the Visual Basic application, which of the following are listed in a properties window?
Correct Answer: Option C — Attributes
Detailed Academic Explanation:
Attributes is the correct answer to “In the Visual Basic application, which of the following are listed in a properties window”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 7 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
The . . . . . . . . include all widow property, form, project ,form layout .
Correct Answer: Option A — ide
Detailed Academic Explanation:
ide is the correct answer to “The . . . . . . . . include all widow property, form, project ,form layout .”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 8 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
Which of the following selects the Cat item, which appears third in the cboAnimal control?
Correct Answer: Option C — cboAnimal.Text = "Cat"
Detailed Academic Explanation:
cboAnimal.Text = "Cat" is the correct answer to “Which of the following selects the Cat item, which appears third in the cboAnimal control”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 9 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
A variable declared as . . . . . . . . type can store both values and it can store date values 01/01/0100 up to 12/31/9999
Correct Answer: Option D — date
Detailed Academic Explanation:
date is the correct answer to “A variable declared as . . . . . . . . type can store both values and it can store date values 01/01/0100 up to 12/31/9999”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 10 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
What happens when maximize box is set to true?
Correct Answer: Option C — Maximize box is enabled
Detailed Academic Explanation:
Maximize box is enabled is the correct answer to “What happens when maximize box is set to true”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 11 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
. . . . . . . . is for displaying a list of directories or folders in a selected drive
Correct Answer: Option D — dirlist box
Detailed Academic Explanation:
dirlist box is the correct answer to “. . . . . . . . is for displaying a list of directories or folders in a selected drive”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 12 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
MDI is used to work as parents, its main property is . . . . . . . . , all the forms are open within MDI
Correct Answer: Option A — mdi child
Detailed Academic Explanation:
mdi child is the correct answer to “MDI is used to work as parents, its main property is . . . . . . . . , all the forms are open within MDI”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 13 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
What does the Start Position Property determine?
Correct Answer: Option A — initial position on the screen
Detailed Academic Explanation:
initial position on the screen is the correct answer to “What does the Start Position Property determine”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 14 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
In . . . . . . . . , The size of array always remains the same-size doesn't change during the program execution.
Correct Answer: Option D — fixed array
Detailed Academic Explanation:
fixed array is the correct answer to “In . . . . . . . . , The size of array always remains the same-size doesn't change during the program execution.”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 15 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
Designers usually include graphics to . . . . . . . . a portion of screen.
Correct Answer: Option B — Emphasize
Detailed Academic Explanation:
Emphasize is the correct answer to “Designers usually include graphics to . . . . . . . . a portion of screen.”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 16 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
What will be assigned to the dblAvg variable after the code has been executed? Do While intSub < 4 intTotal = intTotal + intNums(intSub) intSub = intSub + 1 Loop dblAvg = intTotal / intSub – 1 Dim intNums() As Integer = {10, 5, 7, 2}. The intTotal, intSub, and dblAvg variables contain the number 0 before the loops are processed.
Correct Answer: Option B — 5
Detailed Academic Explanation:
5 is the correct answer to “What will be assigned to the dblAvg variable after the code has been executed? Do While intSub < 4 intTotal = intTotal + intNums(intSub) intSub = intSub + 1 Loop dblAvg = intTotal / intSub – 1 Dim intNums() As Integer = {10, 5, 7, 2}. The intTotal, intSub, and dblAvg variables contain the number 0 before the loops are processed.”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 17 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
A control is locked using . . . . . . . .
Correct Answer: Option A — Lock Controls
Detailed Academic Explanation:
Lock Controls is the correct answer to “A control is locked using . . . . . . . .”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 18 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
The methods which loads the form into memory . . . . . . . . it on screen.
Correct Answer: Option C — display
Detailed Academic Explanation:
display is the correct answer to “The methods which loads the form into memory . . . . . . . . it on screen.”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 19 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
Microsoft ActiveX Data Control 6 is insert from component , it is used to load ADO control.
Correct Answer: Option A — TRUE
Detailed Academic Explanation:
TRUE is the correct answer to “Microsoft ActiveX Data Control 6 is insert from component , it is used to load ADO control.”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 20 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
VB is tool that allows you to develop application in . . . . . . . .
Correct Answer: Option B — gui
Detailed Academic Explanation:
gui is the correct answer to “VB is tool that allows you to develop application in . . . . . . . .”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 21 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
A . . . . . . . . resembles a table.
Correct Answer: Option B — Two-dimensional array
Detailed Academic Explanation:
Two-dimensional array is the correct answer to “A . . . . . . . . resembles a table.”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 22 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
By which button you can display the additional items?
Correct Answer: Option B — Show All Files Button
Detailed Academic Explanation:
Show All Files Button is the correct answer to “By which button you can display the additional items”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 23 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
. . . . . . . . is a numeric variable used for accumulating something.
Correct Answer: Option B — Counter
Detailed Academic Explanation:
Counter is the correct answer to “. . . . . . . . is a numeric variable used for accumulating something.”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 24 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
You refer to the structure variable by its . . . . . . . .
Correct Answer: Option A — Name
Detailed Academic Explanation:
Name is the correct answer to “You refer to the structure variable by its . . . . . . . .”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 25 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
. . . . . . . . is used to separate related controls from other controls in the form.
Correct Answer: Option A — GroupBox
Detailed Academic Explanation:
GroupBox is the correct answer to “. . . . . . . . is used to separate related controls from other controls in the form.”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 26 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
In the following code, the while loop will execute if strId would have been . . . . . . . . Do While strId Like "###*"
Correct Answer: Option A — 123ABC
Detailed Academic Explanation:
123ABC is the correct answer to “In the following code, the while loop will execute if strId would have been . . . . . . . . Do While strId Like "###*"”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 27 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
VB is the example of. . . . . . . .software .
Correct Answer: Option B — front end
Detailed Academic Explanation:
front end is the correct answer to “VB is the example of. . . . . . . .software .”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 28 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
The . . . . . . . . allows us to browse through the various properties, events and methods that are made available to us
Correct Answer: Option D — object browser
Detailed Academic Explanation:
object browser is the correct answer to “The . . . . . . . . allows us to browse through the various properties, events and methods that are made available to us”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 29 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
What will be in Msg after the following code is evaluated? If 3>6 AndAlso 7>4 then Msg="Hi" Else Msg="Bye" EndIf
Correct Answer: Option B — Bye
Detailed Academic Explanation:
Bye is the correct answer to “What will be in Msg after the following code is evaluated? If 3>6 AndAlso 7>4 then Msg="Hi" Else Msg="Bye" EndIf”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 30 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
The intSales array is declared as follows: Dim intSales() As Integer = {10000, 12000, 900, 500, 20000}. The statement intSales(3) = intSales(3) + 10 will .
Correct Answer: Option B — replace the 500 amount with 510
Detailed Academic Explanation:
replace the 500 amount with 510 is the correct answer to “The intSales array is declared as follows: Dim intSales() As Integer = {10000, 12000, 900, 500, 20000}. The statement intSales(3) = intSales(3) + 10 will .”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 31 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
The . . . . . . . . indicates the purpose of the menu element.
Correct Answer: Option A — Caption
Detailed Academic Explanation:
Caption is the correct answer to “The . . . . . . . . indicates the purpose of the menu element.”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 32 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
. . . . . . . . structure can handle conditions with multiple outcomes in an easier manner
Correct Answer: Option A — select case control
Detailed Academic Explanation:
select case control is the correct answer to “. . . . . . . . structure can handle conditions with multiple outcomes in an easier manner”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 33 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
The . . . . . . . . is used to show quick reference to the various elements of a project namely form, classes and modules
Correct Answer: Option B — project explorer
Detailed Academic Explanation:
project explorer is the correct answer to “The . . . . . . . . is used to show quick reference to the various elements of a project namely form, classes and modules”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 34 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
The . . . . . . . . keyword indicates that an application can set the property's value, but it cannot retrieve the value.
Correct Answer: Option C — WriteOnly
Detailed Academic Explanation:
WriteOnly is the correct answer to “The . . . . . . . . keyword indicates that an application can set the property's value, but it cannot retrieve the value.”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 35 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
What does namespace contain?
Correct Answer: Option A — Code that defines a group of related classes
Detailed Academic Explanation:
Code that defines a group of related classes is the correct answer to “What does namespace contain”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 36 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
if condition is end by . . . . . . . .
Correct Answer: Option A — end if condition
Detailed Academic Explanation:
end if condition is the correct answer to “if condition is end by . . . . . . . .”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 37 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
The number that appears after the period in the . . . . . . . . value indicates the order in which the controls were added to the groupbox.
Correct Answer: Option A — Tab index
Detailed Academic Explanation:
Tab index is the correct answer to “The number that appears after the period in the . . . . . . . . value indicates the order in which the controls were added to the groupbox.”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 38 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
. . . . . . . . is used to add a GroupBox to the interface.
Correct Answer: Option A — GroupBox tool
Detailed Academic Explanation:
GroupBox tool is the correct answer to “. . . . . . . . is used to add a GroupBox to the interface.”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 39 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
The . . . . . . . . validator is used to verify that control contains data verify that an entry passes the specified validation logic.
Correct Answer: Option C — CustomValidator
Detailed Academic Explanation:
CustomValidator is the correct answer to “The . . . . . . . . validator is used to verify that control contains data verify that an entry passes the specified validation logic.”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
Question 40 of 40
★ PPSC
★ FPSC
★ PPSC
★ FPSC
The instructions in a . . . . . . . . loop are always processed at least once, whereas the instructions in a . . . . . . . . loop might not be processed at all.
Correct Answer: Option A — Posttest, pretest
Detailed Academic Explanation:
Posttest, pretest is the correct answer to “The instructions in a . . . . . . . . loop are always processed at least once, whereas the instructions in a . . . . . . . . loop might not be processed at all.”. This question is standard in competitive examination syllabi for Visual Basic.
💡Key Conceptual Anchor:Visual Basic
✓Link copied to clipboard
Continue Your Practice
Advanced Mapreduce Concepts — Part 1
Master the next curriculum module with 40 exam-standard MCQs.
In competitive commission exams (FPSC, PPSC, KPPSC, SPSC, CSS, PMS), questions are frequently phrased with distractor options designed to catch rote learners. Whenever you answer an MCQ, read the Detailed Academic Explanation and Conceptual Anchor to understand why the remaining options are incorrect.