![]() | ![]() | ![]() | |
This article has been published [fromdate] |
SCENARIO:
I have Visual Basic 6.0
I want to Dim a variable as WorkSpace.
Been reading on it and wanted to check it out.
Anyway, it doesn't seem to be available. I have the Enterprise edition.
Any thoughts as to why it isn't an option?
Dim ws as WorkSpace...is not working.
SOLUTION
The solution is the following:
- Add a Reference to Microsoft DAO3.x Object Library;
- From VBE (Visual Basic Editor) go to Project ---> References ---> Microsoft DAO3.x Object Library;
Now you could use/declare a [gs variable] as workspace by writing:
Dim variable As DAO.Workspace
...or by using:
Dim variable As Workspace
SOURCE | LINK (Bigresource.com) | LANGUAGE | ENGLISH |
Heelpbook.net – Visual Basic – VBA – How to declare a WorkSpace variable http://heelpbook.altervista.org/2012/visual-basic-vba-how-to-declare-a-workspace-variable/ #heelpbook @heelpbook