What is VBA
VBA is a programming language, programming language is system of statements that are used to control computer.
Accept store data manipulate produce output
Object Oreiented programming Properties methods Events
Access Object Model
Its absolutely huge, hundreds and thousandas of objects, also their huge properties and methods. Can read it in a book but better to look at in Access.
Application Object
Its top level for instance of an Access.
Usefull properties in Current Application object.
1. CurrentDb
DoCmd
Forms
SysCmd
Mthods
DAvg,
DCount
DMax
DMin
DSum
DVar
DVarp
DFirst
DLast
DLookup
Quit
Me Object
Whatever Ojbect that current has focus will be Me Object.
Properties
Active Control
Active Control is field on the form in which user is currently type their data.
AllowAddition, AllowDeletions,
Allow Edits
These properties define either to allow addition, deletion or edit.
AllowFilters, Filter
RecordSource ( Piece of table or query )
ScrollBars ( To hide or display )
Visible (to hide or show the object)
Methods
Refresh
Repaint
Requery
Undo
CurrentDB Object
Properties
Name (Name of form or Dable)
QueryDefs ( look at created query)
TableDefs (Look into type of data and other table properties.)
Methods
CreateQueryDef (Create Query)
CreateTableDef (Create or Change the Dable Defination,)
OpenRecordSet (Open query, table or link to outside)
Recordset Object
Properties
Properties of OpenRecordSet BOF and EOF (to loop through an object to check when the task is done) Field is a record set NoMatch RecordCount
Methods
AddNew Close Delete Edit FindFirst, FindLast, FindNext, FindPrevious MoveFirst, MoveLast, MoveNext, MovePrevious