Thanks Thanks:  0
Likes Likes:  0
Results 1 to 5 of 5

Thread: Saving to a database via a macro

  1. #1
    New Member
    Join Date
    Mar 2002
    Posts
    4
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Listen - i've made an invoice template, & i'm saving some data to a database (.xls-file). i've also written a macro to save the individual invoices - everything works just fine, apart from this: when i'm using the macro to save (ActiveWorkbook.SaveAs) the data isn't saved to the database.

    VERY VERY grateful for help & hints - i've been using this for more than a year, but i still haven't solved this one!

  2. #2
    MrExcel MVP Al Chara's Avatar
    Join Date
    Feb 2002
    Location
    Newark, Delaware
    Posts
    1,701
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    I'm not sure I follow your problem, but maybe you just need to do a regular save also:
    ActiveWorkbook.Save

    Hope this helps.
    Kind regards, Al.

  3. #3
    New Member
    Join Date
    Mar 2002
    Posts
    4
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    won't work - not in a macro - it only works when i save manually

  4. #4
    MrExcel MVP Al Chara's Avatar
    Join Date
    Feb 2002
    Location
    Newark, Delaware
    Posts
    1,701
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Post some of your code

  5. #5
    New Member
    Join Date
    Mar 2002
    Posts
    4
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    hi al
    sorry been out of comission for a while
    i can post some code, but all that is relevant is the mentioned ActiveWorkbook.Save or ActiveWorkbook.SaveAs only that the data isn't saved 2 the database, otherwise it works just fine - my invoices are saved with the so-designed names & everything, but if i want to save data 2 the database/update the database (& i do!), i have to save manually (ex: Ctrl/S) - only then do i get the question "update the existing record" - "create a new record" - "continue without updating" - & it bugs me! because i'm sure THERE IS A WAY 2 do this, & i can't figure it out!

Some videos you may like

User Tag List

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
  •