Results 1 to 2 of 2
  1. #1
    Join Date
    May 2003
    Location
    Maryland
    Posts
    11

    Unanswered: Open Exported Word Doc.

    I am trying to automate the report that comes out of an Access DB that produces the weeks checklist. Various tasks for a given week are stored in a group of tables and that makes sense for the purpose. anyhow.

    DoCmd.OutputTo acOutputReport, stRptName, acFormatRTF, "C:\Documents and Settings\mtnshift.GS\My Documents\Weekly Checklist\Weekly Checklist.rtf"

    Drops the report in RTF format into the proper folder just fine. But for the life of me, I cannot figure out how to open the resulting file via code. Im brandnew to this cross application stuff. Im ok inside of Access all by itself.

    I seem to be opening the word document inside the computer but not on the desktop. I need to open it and preferably maximize it in one go.


    'Set objWRD = New Word.Application
    'objWRD.Documents.Open FileName:="C:\Documents and Settings\mtnshift.GS\My Documents\Weekly Checklist\Weekly Checklist.rtf"


    I know this is basic, but I am "clue free" on this one.
    K did you Flashy thing me, K??

  2. #2
    Join Date
    May 2003
    Location
    Maryland
    Posts
    11

    Red face Fellow Newbies

    Ok, I got it. So far. I did not add the visible=true method to put the open object on the desk top. (So much to learn, So much to learn.)

    It seems to function just fine now. I was wondering if their is any code I need enter to seal the file. Like an old
    Open, Load, close sequence. Thanks for looking BB.

    Set objWRD = New Word.Application
    objWRD.Visible = True
    objWRD.Documents.Open FileName:="C:\Documents and Settings\mtnshift.GS\My Documents\Weekly Checklist\Weekly Checklist.rtf"
    K did you Flashy thing me, K??

Posting Permissions

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