Microsoft Access VBA Macro Programming
The purpose of this chapter is to give you an idea of how you can use API calls within your code. The examples given are not com ...
The next step is to put in code to call this function: Sub Test_Api() Dim x as Double Dim FreeBytesAvailableToCaller As Currency ...
You can check the values by going into Windows Explorer (right-click the Windows Start button in the bottom-left corner of the s ...
x = GetPrivateProfileString("Parameters", "Path", "", s$, 256, "myini.ini") MsgBox s$ MsgBox x End Sub The first line writes the ...
Reading Keyboard Activity Another useful purpose of API calls is to read the keyboard and find out if a certain key has been pre ...
Chapter 20: API Calls 259 Symbolic Constant Name Value (Hexadecimal) Mouse or Keyboard Equivalent VK_LBUTTON 01 Left mouse butto ...
260 Microsoft Access 2010 VBA Macro Programming Symbolic Constant Name Value (Hexadecimal) Mouse or Keyboard Equivalent VK_DELET ...
Chapter 20: API Calls 261 Symbolic Constant Name Value (Hexadecimal) Mouse or Keyboard Equivalent VK_W 57 W VK_X 58 X VK_Y 59 Y ...
262 Microsoft Access 2010 VBA Macro Programming Symbolic Constant Name Value (Hexadecimal) Mouse or Keyboard Equivalent VK_F12 7 ...
Playing Multimedia Sounds You can also use an API call to play a sound within your code from a WAV file. The old macro programmi ...
This page intentionally left blank ...
Chapter 21 Class Modules. Chapter 21 Class Modules. A s you program in VBA and insert modules to hold your code, you will notice ...
property. For example, you could find out the number of fields in the USysRibbons table (see Chapter 11 on how this table is bui ...
Creating an Object You need to set up the actual object for items within the collection first because this has to be used in the ...
Creating a Collection The next stage is to create theCollectionobject to hold the individualMyPNameobjects. Insert another class ...
Next, select theClass_Initializesubroutine. This routine runs when you first use the class and determines what the contents will ...
The Do Until loop adds the objects into the collection from a source of data. This could be an external database, or it could ju ...
MsgBox pn.Item(n).Pname Next n End Sub This creates a new instance of theMyPnamesobject. When this procedure is run, the first t ...
Using the PNames Collection as a Multitier Application Having created a working object model based on your data services layer, ...
Chapter 22 Animation Chapter 22 Animation B elieve it or not, it is possible to animate objects in Access. By taking this possib ...
«
10
11
12
13
14
15
16
17
18
19
»
Free download pdf