Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Forms / October 2007

Tip: Looking for answers? Try searching our database.

DoCmd.TransferDatabase import "FORMS"

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
CWH - 22 Oct 2007 12:34 GMT
I am trying to import new forms into a database using the following vb code.
Of course it doesn't work. Any help here would really be appreicated;

DoCmd.TransferDatabase acImport, "Microsoft Access", "C:\Folder\DBname.mdb",
acForm, "FrmName, frmName"

Thanks
Pieter Wijnen - 22 Oct 2007 13:19 GMT
"FrmName, frmName"
should be
FrmName, frmName

Pieter

>I am trying to import new forms into a database using the following vb
>code.
[quoted text clipped - 5 lines]
>
> Thanks
CWH - 22 Oct 2007 13:59 GMT
Thanks Pieter;

But when I change to statement as suggested I get a 2465 Error can't find the
field "|" referred to in your expression.

>"FrmName, frmName"
>should be
[quoted text clipped - 7 lines]
>>
>> Thanks
Douglas J. Steele - 22 Oct 2007 14:30 GMT
What is FrmName: a variable containing the name of the form, or are you
using that to represent the name of the field?

If it's supposed to be the actual name of the field, use

"FrmName", "frmName"

Signature

Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)

> Thanks Pieter;
>
[quoted text clipped - 13 lines]
>>>
>>> Thanks
CWH - 22 Oct 2007 14:54 GMT
Hi;

Sorry if I'm comfusing. All I want to do is import the form in its entirity
to include all fields etc..

>What is FrmName: a variable containing the name of the form, or are you
>using that to represent the name of the field?
[quoted text clipped - 8 lines]
>>>>
>>>> Thanks
Douglas J. Steele - 22 Oct 2007 15:27 GMT
That's fine, but you need to tell us what FrmName is in the one line of code
you provided.

Perhaps if you showed more of your code...

Signature

Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)

> Hi;
>
[quoted text clipped - 14 lines]
>>>>>
>>>>> Thanks
CWH - 22 Oct 2007 15:43 GMT
DoCmd.TransferDatabase acImport, "Microsoft Access", "C:\Folder\DBname.mdb",
acForm, TrainingMaster, TrainingMaster

Where TrainingMaster is the actual form name. and "C:\folder\DBname.mdb" is
the location where the form is that I want to import into the current
database. My vb code deletes the current form (same name) and then should
import the new one.

Thanks

>That's fine, but you need to tell us what FrmName is in the one line of code
>you provided.
[quoted text clipped - 6 lines]
>>>>>>
>>>>>> Thanks
Douglas J. Steele - 22 Oct 2007 18:11 GMT
In that case, you need

DoCmd.TransferDatabase acImport, "Microsoft Access", "C:\Folder\DBname.mdb",
acForm, "TrainingMaster", "TrainingMaster"

Signature

Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)

> DoCmd.TransferDatabase acImport, "Microsoft Access",
> "C:\Folder\DBname.mdb",
[quoted text clipped - 19 lines]
>>>>>>>
>>>>>>> Thanks
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.