CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 14 of 14

Threaded View

  1. #3
    Join Date
    Jul 2008
    Location
    WV
    Posts
    5,362

    Re: getting the .vbp filename in a vb project

    Could be one line in VB6 as well. By default the vbp filename is the same as the exe filename other than the extension.

    Code:
    ProjectName=app.path &"\" & mid(app.exename,1,len(app.exename)-3) & "vpb"

    The vbp however is typically not part of the files that would be installed on the end users system so this file would not be available at runtime in most cases. Not sure why one would need to do this type of thing.

    One easy way of course would be to simply use dir$() and search app.path for *.vbp files most of the time there will be only one result. In cases where more than one project exist you could read a few lines from each to find the exe name for that project and match it to your app.exename
    Last edited by DataMiser; June 25th, 2010 at 08:02 AM.
    Always use [code][/code] tags when posting code.

Tags for this Thread

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

Featured