Access VBA Macro Programming
Chapter 29 Monitoring Table Statistics Chapter 29 Monitoring Table Statistics I n large complex Access applications, it is diffi ...
Initially, this code sets up a variablewto represent aTableDefobject. This represents the current table definition being cycled ...
No primary key is required since this is an internal table for information only. Save the table with the nametblTableStatistics. ...
the Object Browser for this information because it can be difficult to know what command to use next. It is also easy to make mi ...
Chapter 30 Handling Large Text Files Chapter 30 Handling Large Text Files I n an Access application, you frequently have to eith ...
By default, the Object Browser references two separate object models. This is Access and DAO. The Access object model references ...
For n = 1 To 10 Line Input #fnum, temp Print #fnum1, temp Next n Close fnum Close fnum1 End Sub This code opened the 4GB file (M ...
show the property type and if it is read-only. Clicking a method displays the syntax for parameters and which ones are optional ...
Else temp1 = temp1 & Mid(temp, m, 1) End If Next m Print #fnum1, temp1 Loop Close fnum Close fnum1 End Sub This code opens u ...
Notice the statements to get the field data. An exclamation mark (!) is used instead of a dot (.) because the field names are no ...
Open "c:\SmallFile1.txt" For Output As fnum1 fnum2 = FreeFile Open "c:\SmallFile2.txt" For Output As fnum2 Do While Not EOF(fnum ...
When n=1, the first row of the big file is written to both output files. This is because it was a header row containing field na ...
RecSet.AddNew RecSet!Company = "MyCompany" RecSet![Last Name] = "Shepherd" RecSet![First Name] = "Richard" RecSet.Update RecSet. ...
This page intentionally left blank ...
Set WrkSp = DBEngine.Workspaces( 0 ) WrkSp.BeginTrans Do Until RecSet.EOF If RecSet![First Name] = "Nancy" Then RecSet.Edit RecS ...
Chapter 31 Create and Change Table Structures Chapter 31 Create and Change Table Structures A s your Access application is runni ...
automatic list boxes and providing a full hierarchy in every line of code. This example works with the Northwind database Employ ...
MyTable.Fields.Append MyTable.CreateField("IntegerField", dbInteger) MyTable.Fields.Append MyTable.CreateField("SingleNumberFiel ...
Editing Field Properties You can also edit field properties on-the-fly (providing that the table is not open). Here are some exa ...
does not have properties and methods (commands) that apply to theTableDefobject or the CurrentDbobject. You cannot use aFieldobj ...
«
23
24
25
26
27
28
29
30
31
32
»
Free download pdf