Results 1 to 6 of 6

Thread: $(AppPath) Error.

Hybrid View

  1. #1

    Thread Starter
    New Member
    Join Date
    Feb 2000
    Location
    Wanganui
    Posts
    11

    Post

    At the moment I am using this code:

    cmdGo.Picture = LoadPicture("$(AppPath)\Go.ico")

    And I have the Go.ico file in the same directory. How come I am still getting a cannot find error.

    This is probably a really basic question, but any help would be much appreciated.
    Tommy Boy.

  2. #2
    Junior Member
    Join Date
    Apr 1999
    Location
    Location Greece.
    Posts
    25

    Post

    The corect is

    cmdGo.Picture = LoadPicture(App.Path & "\Go.ico")

    where app.path is the path of your executable program

  3. #3

    Thread Starter
    New Member
    Join Date
    Feb 2000
    Location
    Wanganui
    Posts
    11

    Post

    Thanks heaps.
    Tommy Boy.

  4. #4
    Guest

    Post

    but what occurs if you're app is istalled at c:\ ???

    better you use a other routine: (past it into a module)


    Public Function AppPath () as String
    dim strBuffer as string
    if right(app.path,1) = "\" then
    apppath = mid(app.path,1,len(app.path) - 1)
    else
    apppath = app.path
    end if
    end function

    Edited by taLON on 02-28-2000 at 06:35 AM

  5. #5
    Junior Member
    Join Date
    Apr 1999
    Location
    Location Greece.
    Posts
    25

    Post

    Yes you have right.

    I forgot it because sometimes the mind goes faster.....

  6. #6

    Thread Starter
    New Member
    Join Date
    Feb 2000
    Location
    Wanganui
    Posts
    11

    Post Uh, Johnny boy, r u from around these parts?

    ...
    Tommy Boy.

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