CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 12 of 12
  1. #1
    Join Date
    Dec 2014
    Posts
    27

    Where are my programs?

    I've written a few dozen programs in VB (Ver. 5.0). I presume they reside somewhere on the hard disk in my PC, but where are they? When I'm in the VB programming environment, I can access them to edit ("File" > "Open Project") and run. There, they have names like "breaker.vbp", "calcu.vbp", and "check.vbp". These look like file names to me, but when I ask Windows to find them ("Start" > "Start Search"), I always get "No items match your search". I want to "grab" them to migrate them to a new computer, but I can't find where they are located.

  2. #2
    Arjay's Avatar
    Arjay is offline Moderator / EX MS MVP Power Poster
    Join Date
    Aug 2004
    Posts
    13,490

    Re: Where are my programs?

    Where does File\Open Project point to? Wouldn't the files you are looking for be in the same place?

  3. #3
    Join Date
    Dec 2014
    Posts
    27

    Re: Where are my programs?

    Thank you, Arjay, that's a partial solution. I found three of my 48 programs there. The other 45 are still in limbo.
    Even those are not found by Windows's "Start Search", so part of the problem seems to be "Start Search".

  4. #4
    2kaud's Avatar
    2kaud is offline Super Moderator Power Poster
    Join Date
    Dec 2012
    Location
    England
    Posts
    7,824

    Re: Where are my programs?

    From a command prompt try

    Code:
    cd \
    dir *.vbp /s/a/o/p
    This should display the names and locations of all the files that end .vbp on your computer.
    All advice is offered in good faith only. All my code is tested (unless stated explicitly otherwise) with the latest version of Microsoft Visual Studio (using the supported features of the latest standard) and is offered as examples only - not as production quality. I cannot offer advice regarding any other c/c++ compiler/IDE or incompatibilities with VS. You are ultimately responsible for the effects of your programs and the integrity of the machines they run on. Anything I post, code snippets, advice, etc is licensed as Public Domain https://creativecommons.org/publicdomain/zero/1.0/ and can be used without reference or acknowledgement. Also note that I only provide advice and guidance via the forums - and not via private messages!

    C++23 Compiler: Microsoft VS2022 (17.6.5)

  5. #5
    Arjay's Avatar
    Arjay is offline Moderator / EX MS MVP Power Poster
    Join Date
    Aug 2004
    Posts
    13,490

    Re: Where are my programs?

    Do you need to look for .exe files rather than *.vbp files? I forgot whether vb5 can produce a standalone exe.

  6. #6
    Join Date
    Dec 2014
    Posts
    27

    Re: Where are my programs?

    Thanks for your follow-up, Arjay.
    VB5 does produce an exe file if you request it, and I haven't had trouble finding those.
    (In fact, if I remember correctly, it has the courtesy to ask you where you'd like the exe to be stored.)
    Some of my programs, in addition to the *.vbp file, have a same-named *.vbw file, and others, in addition to these two, have a *.frm and a *.frx file.
    I presume I need all four files in order to continue editing the program after migrating to the new computer—am I right?

  7. #7
    Arjay's Avatar
    Arjay is offline Moderator / EX MS MVP Power Poster
    Join Date
    Aug 2004
    Posts
    13,490

    Re: Where are my programs?

    Quote Originally Posted by leezinho View Post
    Thanks for your follow-up, Arjay.
    VB5 does produce an exe file if you request it, and I haven't had trouble finding those.
    (In fact, if I remember correctly, it has the courtesy to ask you where you'd like the exe to be stored.)
    Some of my programs, in addition to the *.vbp file, have a same-named *.vbw file, and others, in addition to these two, have a *.frm and a *.frx file.
    I presume I need all four files in order to continue editing the program after migrating to the new computer—am I right?
    I'm not a VB expert, but you'll need all the related source files (.vbp, .vbw, .vb, etc.).

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

    Re: Where are my programs?

    Quote Originally Posted by leezinho View Post
    Thanks for your follow-up, Arjay.
    VB5 does produce an exe file if you request it, and I haven't had trouble finding those.
    (In fact, if I remember correctly, it has the courtesy to ask you where you'd like the exe to be stored.)
    Some of my programs, in addition to the *.vbp file, have a same-named *.vbw file, and others, in addition to these two, have a *.frm and a *.frx file.
    I presume I need all four files in order to continue editing the program after migrating to the new computer—am I right?
    Yes you need all files used by the project You will always have a vbp, vbw and frm you will likely have a frx and you may have others such as .bas .cls .ctl .res
    If you open the vbp file in notepad many [possibly all] of the files used will be listed there. You definitely need any thing that is listed there which may also include dll and ocx files that are located in the Windows/System ... folders in addition you may have mdb files txt files ico, jpg, bmp and possibly any number of others all depending on what your project does and how it was created.

    Also note that any files which are not in the same folder as the vbp will have a path shown in the vbp as well the path may be relative or literal depending on the location of the file in question.

    by default Vb5 saves projects in the folder where the VB.Exe file is located. You can of course save them anywhere but on any OS after XP the default location is problematic and should not be used.
    Always use [code][/code] tags when posting code.

  9. #9
    Join Date
    Dec 2014
    Posts
    27

    Re: Where are my programs?

    Belated thanks to 2kaud (#4) for the advice to use Command Prompt for finding files.
    It detects folders that are invisible to any other finder:
    Windows Explorer, Notepad, and Open Office (where to save?) are all unable to "see" those folders.
    And yet those invisible folders contain files whose names only I could have written.
    I assume Visual Basic saved them there without asking my permission. Well, they certainly are safe from any meddling.
    So far, I haven't been able to access them for editing.
    It seems my only recourse is to ask Command Prompt to "type" them on the screen, and then Print Screen and maybe have to re-key them.
    But anyhow, 2kaud, I'm grateful for your suggestion of Command Prompt.
    I'm old enough to remember DOS, so relearning it is easier than having to face it as something new.

  10. #10
    2kaud's Avatar
    2kaud is offline Super Moderator Power Poster
    Join Date
    Dec 2012
    Location
    England
    Posts
    7,824

    Re: Where are my programs?

    I'm old enough to remember DOS, so relearning it is easier than having to face it as something new
    Yep!

    If you can 'type' them and they have the content you want, then you can re-direct the output to a file in another folder using >. You should also be able to use the copy command to copy them to another folder.

    The issue is why you can't see them. If you open Folder Options in the Control Panel then View and set Show hidden files, folders and drives you should be able to see them in Explorer.
    Last edited by 2kaud; October 25th, 2017 at 01:46 PM.
    All advice is offered in good faith only. All my code is tested (unless stated explicitly otherwise) with the latest version of Microsoft Visual Studio (using the supported features of the latest standard) and is offered as examples only - not as production quality. I cannot offer advice regarding any other c/c++ compiler/IDE or incompatibilities with VS. You are ultimately responsible for the effects of your programs and the integrity of the machines they run on. Anything I post, code snippets, advice, etc is licensed as Public Domain https://creativecommons.org/publicdomain/zero/1.0/ and can be used without reference or acknowledgement. Also note that I only provide advice and guidance via the forums - and not via private messages!

    C++23 Compiler: Microsoft VS2022 (17.6.5)

  11. #11
    Join Date
    Dec 2014
    Posts
    27

    Re: Where are my programs?

    Folder Options. Aha! Thanks!

  12. #12
    Join Date
    Dec 2014
    Posts
    27

    Re: Where are my programs?

    After nearly 20 years of programming with VB (5.0), I've discovered (this week) that I could have controlled where the resulting files were located.
    Finding where they are now, I conclude that I sometimes accidentally accepted file names provided by the IDE, including "3", "+", and "ð" (a phonetic symbol that is not on the keyboard!). Thank you all for your patience with my ignorant questions.

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