Consulting

Results 1 to 2 of 2

Thread: How to link to a file one folder up.

  1. #1
    VBAX Regular kane's Avatar
    Joined
    Mar 2005
    Location
    Huntsville, AL
    Posts
    35
    Location

    How to link to a file one folder up.

    I'm using this code in a file called main.xls which is in folder1.
    ActiveWorkbook.FollowHyperlink "base.xls"

    I'm using this code to link to base.xls which is outside folder1.

    What do I need to do to get this to link to a file right outside the folder?

    Thx,

  2. #2
    VBAX Regular kane's Avatar
    Joined
    Mar 2005
    Location
    Huntsville, AL
    Posts
    35
    Location

    I got this to work.

    I got what I wanted with this. Where the name of the folder was "1.0"

    Dim FilePathIs
    FilePathIs = Left(ThisWorkbook.Path, Len(ThisWorkbook.Path) - 3)
    ActiveWorkbook.FollowHyperlink FilePathIs & "Base.xls"

    Any better ideas still accepted.

Posting Permissions

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