path of executable

  1. last year


    how can i get the path of my own program?

    I.e. my program was started from 'c:\myprogram\program.exe'
    and i want to show the path in a messagebox.


    Hi all,

    thx for the fast answers.

    Problem solved.


  2. Andrew L

    19 Apr 2017 San Francisco, CA, USA

    Use the App.ExecutableFile property.


  3. Dave S

    19 Apr 2017 San Diego, California USA

    per the lang ref

    Property (As FolderItem)
    The property is read-only.

    FolderItemValue = aApplication.ExecutableFile
    Returns a FolderItem for the actual executable application even if it is in a bundle.


    Use the properties and methods of the FolderItem class to get/set attributes of the executable file and/or perform operations. For example:
    gets the full path to the executable.
    gets the date/time the executable was created.

  4. see

  5. Hi all,

    thx for the fast answers.

    Problem solved.


  6. Hi Andrew,

    Problem solved, but...


    gives me the path + the name of the executable, but how
    do i get only the path (w/o the name of the executable)?


  7. Jeff T

    19 Apr 2017 Midlands of England, Europe

  8. Tim P

    19 Apr 2017 Pre-Release Testers, XDC Speakers

    Please try searching the documentation at some point.

  9. Hi Tim,

    i had a long day and laziness kicked in.

    But you're right.


  10. 12 months ago

    David C

    20 Apr 2017 Pre-Release Testers, Xojo Pro Derby, ITM

    Next time click the message that best answered it, rather than yourself. It helps the TLDR folks.

or Sign Up to reply!