Visual Basic Objective Question Paper

Tuesday, March 18, 2008

1. A VB Project (.vbp) consists of forms, code modules and (Chose one or more than one)
A. Custom controls
B. Database
C. Environment settings
D. PL/SQL procedures

2. When an object is created it is assigned a default name based on its object type?
A. True
B. False

3. What all we can call within the VB Program? (Chose one or more than one)
A. Exe
B. Dll
C. Cls
D. None of the above

4. We can manage release version through VB?
A. true
B. false

5. What controls can be placed on VB MDI Form?
A. timer control
B. command button
C. text box
D. picture box

6. Sequence of events in form loading?
A. Initialize Load Resize Activate GotFocus Paint
B. Load Initialize Activate Resize GotFocus Paint
C. GotFocus Initialize Paint Resize Load Activate
D. Activate Initialize Paint Load Resize GotFocus


7. Which statement is true?
A. exe can run independently
B. dll can run independently
C. exe and dll both can run independently
D. none of the above

8. Which of the following statement(s) is/are true
A. Declaration of Option Explicit is mandatory
B. If we define option explicit, then declaration of variables is must
C. If we define option explicit, then declaration of variables is not required


9. What will be the output of the following program

Private Sub Command1_Click()
a=10
On Error GoTo myLabel
b = a / 0
MsgBox (b)

myLabel:
Resume Next
End Sub
A. Program will give compilation error
B. program will run and show blank message box
C. program will not run at all
D. 10/0 will be shown in the message box


10. Which of the following is/are not a valid type(s) of recordset?
A. Table-type
B. Dynaset-type
C. Dynamic-type
D. Cursor-Type


11. What are the objects of ADO?
A. Command
B. Connection
C. Recordset
D. Database


12. Which of the following is/are faster?
A. Inprocess
B. Out of Process
C. DLL
D. EXE


13. What is a bookmark?
A. Variant
B. Integer
C. It uniquely identifies a particular column in a database
D. It uniquely identifies a particular row in a database


14. We need separate ODBC drivers for each database type?
A. true
B. false


15. What will be the output of the following program? (Assuming end_date as 18th March 2008)
Private Sub Command1_Click()
Dim start_date As Date
Dim end_date As Date
Dim NoOfDays As Integer

NoOfDays = 0
start_date = "01/01/2008"
end_date = Date

While (start_date <> "SUNDAY" And UCase(WeekdayName(Weekday(start_date))) <> "SATURDAY") Then
NoOfDays = NoOfDays + 1
End If
start_date = start_date + 1
Wend
MsgBox (NoOfDays)
End Sub
A. 55
B. 56
C. 54
D. 57


0 comments:

Post a Comment

Chitika

About This Blog

Followers

  © Blogger template The Professional Template II by Ourblogtemplates.com 2009

Back to TOP