team lib
  1. Modify the frmCriteria form by giving it a custom property of type Long and called TimesOpened . Then you should try to write some code that increments the value of this new property whenever the form is opened.

    The Kernel32 dynamic link library contains a function called GetWindowsDirectory which returns the path to the Windows directory. You can declare the function like this in VBA:

     Private Declare Function GetWindowsDirectoryA Lib "kernel32" _    (ByVal strBuffer As String, ByVal lngSize As Long) As Long 

    The first argument should be passed as a fixed-length string and will be populated by the function with a string representing the path to the Windows directory. You should populate the second variable ( lngSize ) with the length of strBuffer before you call the GetWindowsDirectory function. The GetWindowsDirectoryA function returns a long integer denoting the length (max. 255 ) of the value it has placed in strBuffer .

  2. Use this function to create a VBA procedure called GetWinDir that accepts no arguments and simply returns the path to the Windows directory.

  3. What is the difference between, and effect of, passing an argument ByVal & ByRef ?

  4. What is the default method of passing an argument in VBA?

team lib

Beginning Access 2002 VBA
Beginning Access 2002 VBA (Programmer to Programmer)
ISBN: 0764544020
EAN: 2147483647
Year: 2003
Pages: 256

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net