Hi I am trying to develop a Database application with VB6 and MS ACCESS.
Sub Main()
' First we initialize paths for all needed files
gstrDBPath = "c:\dvp\PBG "
gOrderDetailsPa th = "c:\dvp\PBG\Ord erDetail.txt"
'gOrderDetailsP ath = "G:\order.t xt"
'Load frmImportData
'frmImportData. Show
Set gdbFML = OpenDatabase(gs trDBPath & "\WVCommon.mdb" )
frmImportData.S how
Dim frm As Form
' Loop through all open forms and close them
For Each frm In Forms
Unload frm
Next frm
End Sub
This is the code in my "module".
Now when I uncomment
'Load frmImportData
I get a Runtime error 91
at the statement in the form where I am using the following line
Set rs = gdbFML.OpenReco rdset(strSQL)
I went thru the forms here and realized I may not have added the needed reference but the only problem is I dont know which reference is needed.
Could somene plz help me out with this plz.
Sub Main()
' First we initialize paths for all needed files
gstrDBPath = "c:\dvp\PBG "
gOrderDetailsPa th = "c:\dvp\PBG\Ord erDetail.txt"
'gOrderDetailsP ath = "G:\order.t xt"
'Load frmImportData
'frmImportData. Show
Set gdbFML = OpenDatabase(gs trDBPath & "\WVCommon.mdb" )
frmImportData.S how
Dim frm As Form
' Loop through all open forms and close them
For Each frm In Forms
Unload frm
Next frm
End Sub
This is the code in my "module".
Now when I uncomment
'Load frmImportData
I get a Runtime error 91
at the statement in the form where I am using the following line
Set rs = gdbFML.OpenReco rdset(strSQL)
I went thru the forms here and realized I may not have added the needed reference but the only problem is I dont know which reference is needed.
Could somene plz help me out with this plz.
Comment