I have included the following code to open an Access database form from
within an exsisting Access database. But when I run the code, it
appears that it opens the database because in windows explorer I can see
the database has the .ldb file extension. So it appears that it's open,
but I can't see the database or the form that I've tried to open. What
am I doing wrong. The following is the code:
'This is in the declaration part of the module
Dim appAccess As Access.Applicat ion
' Initialize string to database path.
Const strConPathToSam ples = "C:\Documen ts and Settings\My
Documents\Cares et Data Verification\Er ror Log Database.mdb"
strDB = strConPathToSam ples & "Error Log Database.mdb"
' Create new instance of Microsoft Access.
Set appAccess = CreateObject("A ccess.Applicati on")
' Open database in Microsoft Access window.
appAccess.OpenC urrentDatabase strConPathToSam ples
' Open form.
appAccess.DoCmd .OpenForm "Import Error Logs", acNormal
Thanks in advanced,
bailee220
--
Posted via
http://dbforums.com