Question about getting directory info

Ok, I know that calling CurDir() will give you the 'active' directory. This has got to be really basic, but how do you just access the directory that the program is running in. (Without using the registry or something like that...) Usually the reason I need to use this is loading external files (like a music file that you want playing or whatever) and the only way I can get it is to either: 1) Use Win Explorer to go to that directory and therefore set it as the default dir. or 2) Refer to it by it's path. Neither option is pretty. I dug around in help for a while and couldn't find anything... Like I said, this has gotta be really easy to fix. Any help will be appreciated :)



  • Yep your right, it is really easy.

    app.path is what you use to get the directory that

    the application is running in.


    dim ProgDir as String

    ProgDir = App.Path

    -The App function has lots of useful properties you

    can use in your program. Highlight App in VB and

    press F1.

    Hope this helps,


Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!