Results 1 to 4 of 4

Thread: Error 5174 - File could not be found

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Jan 1999
    Location
    Scarsdale, NY
    Posts
    26

    Post

    Hello,

    I'm trying to open a document, and I think I was successful in doing so about 30 min ago, but now I get an error (Run-time error 5174: "This file could not be found")
    But!!! The file DOES exist!!!

    Please, help me if you can!

    Thank you!

    Here's my code:

    Set wrd = CreateObject("Word.Application")

    fileout = "C:\Test.rtf"
    wrd.Documents.Open fileout

  2. #2
    Hyperactive Member
    Join Date
    Jun 1999
    Location
    Calgary Alberta
    Posts
    359

    Post

    Well, I've only done this is Access using VBA but I do the same except:


    wrd.Application.Documents.Open fileout

    I have Application between the wrd object and Documents. I'm not sure whether this is particular for VBA or not though. Give it a shot. Hope it helps.

  3. #3

    Thread Starter
    Junior Member
    Join Date
    Jan 1999
    Location
    Scarsdale, NY
    Posts
    26

    Post

    Nope, that didn't work.
    It looks like the very first time I open a document, it's fine. After that - it gives me the error.

  4. #4
    Junior Member
    Join Date
    Nov 1999
    Posts
    26

    Post

    Maybe you need to close the file when the Program quits, because it sounds like its staying in memory as being open.

    Just a thought.

    ------------------
    Quadrex
    [email protected]
    Quadrex Programming


Posting Permissions

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



Click Here to Expand Forum to Full Width