A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Database Design
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Can you import objects via code?



 
 
Thread Tools Display Modes
  #1  
Old April 22nd, 2009, 02:59 PM posted to microsoft.public.access.tablesdbdesign
drt
external usenet poster
 
Posts: 4
Default Can you import objects via code?

I am trying to create a form in MS Access that works similar to Windows
Update (i.e. will check the version of a local form / report and, if
different, will delete it from the local database and then import from a
master). I can get the form to delete using 'DeleteObject' but cannot find
the equivalent command for import ... any suggestions?
  #2  
Old April 22nd, 2009, 05:38 PM posted to microsoft.public.access.tablesdbdesign
Andrew Tapp
external usenet poster
 
Posts: 6
Default Can you import objects via code?

You could try the DoCmd.CopyObject [destinationdatabase][, newname][,
sourceobjecttype][, sourceobjectname] method.

Hope this helps.

"DRT" wrote:

I am trying to create a form in MS Access that works similar to Windows
Update (i.e. will check the version of a local form / report and, if
different, will delete it from the local database and then import from a
master). I can get the form to delete using 'DeleteObject' but cannot find
the equivalent command for import ... any suggestions?

  #3  
Old April 22nd, 2009, 05:41 PM posted to microsoft.public.access.tablesdbdesign
Andrew Tapp
external usenet poster
 
Posts: 6
Default Can you import objects via code?

Actually the DoCmd.TransferDatabase [transfertype], databasetype,
databasename[, objecttype], source, destination[, structureonly][,
saveloginid] may be of more help as it allows you to import from a database.

Hope this helps.

"DRT" wrote:

I am trying to create a form in MS Access that works similar to Windows
Update (i.e. will check the version of a local form / report and, if
different, will delete it from the local database and then import from a
master). I can get the form to delete using 'DeleteObject' but cannot find
the equivalent command for import ... any suggestions?

  #4  
Old April 22nd, 2009, 07:24 PM posted to microsoft.public.access.tablesdbdesign
Jeff Boyce
external usenet poster
 
Posts: 8,621
Default Can you import objects via code?

Another approach, rather than swapping objects in and out of an Access file,
is to swap the entire Access file out and replace it with an updated
version.

That way, any (and all) changes you've made (and tested) will be
available...

Good luck

Regards

Jeff Boyce
Microsoft Office/Access MVP

"DRT" wrote in message
...
I am trying to create a form in MS Access that works similar to Windows
Update (i.e. will check the version of a local form / report and, if
different, will delete it from the local database and then import from a
master). I can get the form to delete using 'DeleteObject' but cannot
find
the equivalent command for import ... any suggestions?



  #5  
Old April 23rd, 2009, 08:29 AM posted to microsoft.public.access.tablesdbdesign
drt
external usenet poster
 
Posts: 4
Default Can you import objects via code?

Thanks all for the response, should be able to get something working now

"Andrew Tapp" wrote:

Actually the DoCmd.TransferDatabase [transfertype], databasetype,
databasename[, objecttype], source, destination[, structureonly][,
saveloginid] may be of more help as it allows you to import from a database.

Hope this helps.

"DRT" wrote:

I am trying to create a form in MS Access that works similar to Windows
Update (i.e. will check the version of a local form / report and, if
different, will delete it from the local database and then import from a
master). I can get the form to delete using 'DeleteObject' but cannot find
the equivalent command for import ... any suggestions?

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 04:29 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.