M
Mike Webb
The author of the database is Roger Carlson.
My skill level: Beginner
I am trying to duplicate his frmCreateSelectGl actions in my database and
ran into a problem with the VB code. I differed from his sample in that I
created a Make Table query to create one table from 2 tables and a join
table. I created a form that is supposed to use the input from combo boxes
to create a query. The problem code is pasted below:
Private Sub cmdRunQuery_Click()
On Error GoTo Err_cmdRunQuery_Click
Dim db As Database
Dim qdf As Access
Dim strSQL As String
When I click the SAVE button in Visual Basic after inserting the code, I get
an error "Compile error. User-defined type not defined." When I click OK
on that dialog box, I see "Private Sub cmdRunQuery_Click()" highlighted in
yellow and "Dim db As Database" highlighted in blue - actually just "db As
Database".
I looked it up in HELP and got lost on where to proceed with the info
presented as possible causes. I looked back over the sample database and
did not find a macro or module, so I'm at a loss on what I did different.
I am running Access 2K2.
TIA,
Mike
My skill level: Beginner
I am trying to duplicate his frmCreateSelectGl actions in my database and
ran into a problem with the VB code. I differed from his sample in that I
created a Make Table query to create one table from 2 tables and a join
table. I created a form that is supposed to use the input from combo boxes
to create a query. The problem code is pasted below:
Private Sub cmdRunQuery_Click()
On Error GoTo Err_cmdRunQuery_Click
Dim db As Database
Dim qdf As Access
Dim strSQL As String
When I click the SAVE button in Visual Basic after inserting the code, I get
an error "Compile error. User-defined type not defined." When I click OK
on that dialog box, I see "Private Sub cmdRunQuery_Click()" highlighted in
yellow and "Dim db As Database" highlighted in blue - actually just "db As
Database".
I looked it up in HELP and got lost on where to proceed with the info
presented as possible causes. I looked back over the sample database and
did not find a macro or module, so I'm at a loss on what I did different.
I am running Access 2K2.
TIA,
Mike