Results 1 to 4 of 4

Import Form

This is a discussion on Import Form within the Microsoft Access forums, part of the Question Forums category; Hello All, How do you transfer a form and module via vba to another db? I can do this with ...

  1. #1
    Board Regular
    Join Date
    Mar 2002
    Location
    So Cal
    Posts
    380

    Default

    Hello All,
    How do you transfer a form and module via vba to another db?

    I can do this with SQL but how do you transfer an object?

    Thanks

    Dan

  2. #2
    MrExcel MVP Russell Hauf's Avatar
    Join Date
    Feb 2002
    Location
    Beaverton, OR USA
    Posts
    1,401

    Default

    Do you need to do it via code?

    If not, you can just right-click in the database window or go to File-Get External Data-Import, select the database, and then import the form. The form's module will be imported with the form.

    If you really want to do it via code, look up the TransferDatabase method in Help.

    HTH,

    Russell

  3. #3
    Board Regular
    Join Date
    Mar 2002
    Location
    So Cal
    Posts
    380

    Default

    Hi Russel,
    Yes I know how to do this manually.......

    I am breaking up one large DB (not the one we worked on last week) that is over 1 million lines. Well the file is too large to work with, so I am breaking up the db into multiple databases's (one for each of my locations - around 45 db) and would rather have the form tranferred with the main data (I have the creation of the db and the transferring of data automated and would perfer to have all automated..)

    Thanks

    Dan

    Edit - The module I need transferred is not the form class module.

    [ This Message was edited by: dtaylor on 2003-02-10 13:06 ]

  4. #4
    MrExcel MVP Russell Hauf's Avatar
    Join Date
    Feb 2002
    Location
    Beaverton, OR USA
    Posts
    1,401

    Default

    The TransferDatabase method will work for both.

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


DMCA.com