Difference between revisions of "Visual Basic for Applications"
Jump to navigation
Jump to search
(Added Tricks) |
|||
| Line 35: | Line 35: | ||
;Solution | ;Solution | ||
:[[Decompile Microsoft Access Database|Decompile your database]] | :[[Decompile Microsoft Access Database|Decompile your database]] | ||
| + | |||
| + | == Tricks == | ||
| + | * If you need to use keywords in an enumeration, for example, you can escape the keyword check with square brackets: | ||
| + | <syntaxhighlight lang="vb"> | ||
| + | Public Enum Keyword | ||
| + | [Boolean] = 1 | ||
| + | [Integer] = 2 | ||
| + | [String] = 3 | ||
| + | End Enum | ||
| + | </syntaxhighlight> | ||
Revision as of 13:28, 18 June 2016
General
Conventions
Concepts
Code
Problems and solutions
Double code execution
- Problem
- The function provided with the OnAction property is executed twice.
- Solution
- Put the function name in single quotes:
.OnAction="'functionname'"
Corrupt Microsoft Access database
- Problem
- Microsoft Access gives strange errors, when trying to compile the project.
- Solution
- Decompile your database
Tricks
- If you need to use keywords in an enumeration, for example, you can escape the keyword check with square brackets:
Public Enum Keyword
[Boolean] = 1
[Integer] = 2
[String] = 3
End Enum