A: Optimistic locking is in effect for editing. The 2K page containing the
record is not locked until the Update method is executed.
What kind of error is the most expected with optmistic lock? Data changed;
If recordset.lockedits=false, which would be the most like to occur:
A. update error: record locked on
B. save error: record locked on
C. can not read database...
Incorporate dynamic-link libraries (DLLs) into an application.
•Declare and call a DLL routine.
Q: How to declare a DLL with a C Char datatype?
A: ByVal variable As Byte
Declare Function Publicname Lib "libname" [Alias "alias"] [Arguments List]
Empty value ByVal 0&, vbNullString
Char ByVal a As Byte
Asciiz String ByVal as String
There are 2 deferent DLL from 2 vendors and the DLL have the same name.
What must you do to be able to call both functions?
A. modify function name in one
B. declare public in separate module use the alias keyword to
C. declare private rename one function *
D. Use the alias keyword to rename one function *
We obtained many DLL functions from different vendors. Two functions happen
to have the same name but different purposes. What can we do?
A. Using an alias *
B. Declaring each Private in separate modules *
C. Registering one with another name
D. Modifying the DLL function.
Pass argument contain address of a Vb subroutine named MyProc to a MicWind
A. Aressof := MyProc
B. Adressof Me.MyProc
C. Adressof MyProc *
D. Adressof (MyProc)
Which code will create a new instance of object named Form1 in Project1?
A. Dim Frmx As Form1
B. Dim Frmx As New Form1 *
C. Set Frmx = Form1
D. Set Frmx = GetObject("Project1.Form1")
How many instances of class1 after running exist after the following code?
Dim a As Class1
Dim b As new Class1
b.MyProperty = 3
Set a = new Class1
C. 2 *
In which case is a new object created? set x=new form1
Which Option will not allow to create instances : set Public to FALSE
Create an Automation server that exposes objects, properties, methods, and
Q: The differences between early binding vs. late binding
•A: Late binding occurs when the compiler does not know about an object
until run time.
Early binding occurs when Visual Basic knows at compile time exactly which
interface will be used with an object variable.
Which two required for Early Binding?
A. Type library *
B. Dual Interface
C. New Keyword *
D. CreateObject Function
For Early Binding
Dim Varnaem as Class
Set varname = CreateObject(ClassName)
Create and use an ActiveX control.
•Declare and raise events.
How to raise an event?
First to declare it, use the Event keyword, then Raise it.
e.g. RaiseEvent ABC (arguments)
How Project Groups can be used when debugging ActiveX controls(lots of Qs).
Ambient & Extender
What is the property of a container that can be used to change the
background color of the control on the container when the background color
of the container changes?
A. Ambient *
D. Property Pages
How do you create a license package file containing the licensing
information for all controls on a Web page?
A. With the Visual Basic License Manager.
B. With the CODEBASE parameter of an HTML page's