![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
Debugging code I didn't write and a novice to VB. The following code is set up as a module within an Access Database: Public Function FixProjNum() Dim db As Database, tbl As TableDef, fld As Field 'Set up pointers (databse/table/field) Set db = DBEngine.Workspaces(0).OpenDatabase(0) Set tbl = db.TableDefs("testing") Set fld = tbl("ChangeMe") 'Change ChangeMe to Integer data type fld.Type = dbInteger End Function The above error is the error message I get when doing a "step into" through the code in attempt to find the error. The "Runtime error 3024 could not find file '0'" appears after clicking step into after the following line is highlighted yellow: Set db = DBEngine.Workspaces(0).OpenDatabase(0) Don't have any idea where to go with this, not sure where the workspaces and opendatabase functions are, if this is what they are etc.... Any help? |
![]() |
| Thread Tools | |
| Display Modes | |
| |