Saving a version of a Visual Basic 6 project
I’m writing this one up as it took me hours to locate an answer on the net.
I had been working on a project in Visual Basic 6. The project was issued and distributed and I had to move on to adding new features. I wanted to do this by saving a copy of the project elsewhere so that I could try out new ideas in a sandbox type environment and keep the original intact. This I did.
BUT, a bug or two were flagged after some weeks and when I returned to the original project folder to make minor ammends, to my horror, the original project files had changed!! After a few experiments, it was clear that whichever version I changed, it always changed the other. I even renamed the directories they were in and still it occurred.
After some considerable searching I found this article which explained that the .vbp project file is actually a simple text file. Open it in Notepad and you will see it full of paths.
It turned out that many of the files I was working on were never even in the folders I thought, but c:\windows. I have no idea how they ended up there.
So gather together all of the files as referenced in your .vbp file, then change the paths in the file to relative ones to point at the folder you now have them all stored in.
Weird! I hope this helps someone else.