Results 1 to 12 of 12

Thread: Creating new versions of a VB program

  1. #1

    Thread Starter
    Member
    Join Date
    Dec 2011
    Location
    Melbourne
    Posts
    37

    Creating new versions of a VB program

    When I am developing a project and making some big changes, I like to create a second version of my project and work on that. After doing this yesterday, I lost a lot of new work and want to check whether the way I create my new version has flaws. I had my project in a folder in a Microsoft OneDrive folder:
    C:\Users\MyName\OneDrive\Documents\Visual Studio 2022\BankSim02
    I copied this whole folder into
    C:\Users\MyName\OneDrive\Documents\Visual Studio 2022\BankSim03

    Are there better ways of creating versions of programs

  2. #2
    Angel of Code Niya's Avatar
    Join Date
    Nov 2011
    Posts
    9,017

    Re: Creating new versions of a VB program

    I think GitHub has strong versioning features. You might want to think about hosting your project there.
    Treeview with NodeAdded/NodesRemoved events | BlinkLabel control | Calculate Permutations | Object Enums | ComboBox with centered items | .Net Internals article(not mine) | Wizard Control | Understanding Multi-Threading | Simple file compression | Demon Arena

    Copy/move files using Windows Shell | I'm not wanted

    C++ programmers will dismiss you as a cretinous simpleton for your inability to keep track of pointers chained 6 levels deep and Java programmers will pillory you for buying into the evils of Microsoft. Meanwhile C# programmers will get paid just a little bit more than you for writing exactly the same code and VB6 programmers will continue to whitter on about "footprints". - FunkyDexter

    There's just no reason to use garbage like InputBox. - jmcilhinney

    The threads I start are Niya and Olaf free zones. No arguing about the benefits of VB6 over .NET here please. Happiness must reign. - yereverluvinuncleber

  3. #3

    Thread Starter
    Member
    Join Date
    Dec 2011
    Location
    Melbourne
    Posts
    37

    Re: Creating new versions of a VB program

    Quote Originally Posted by Niya View Post
    I think GitHub has strong versioning features. You might want to think about hosting your project there.
    I was wondering whether Onedrive might have been a problem - but do not know what GitHub is, or how it could help in this situation.

    I suspect that even though I have duplicated my entire program in folder BankSim03, VB may still be using or altering files in my original folder BankSim02

  4. #4

    Thread Starter
    Member
    Join Date
    Dec 2011
    Location
    Melbourne
    Posts
    37

    Re: Creating new versions of a VB program

    Also, if I changed where I stored my folders like BankSim02, I would probably store them on my own hard drive and back up when the project was complete to OneDrive or similar.

  5. #5
    Angel of Code Niya's Avatar
    Join Date
    Nov 2011
    Posts
    9,017

    Re: Creating new versions of a VB program

    Quote Originally Posted by Persist View Post
    I was wondering whether Onedrive might have been a problem -
    Not really. But it can become messy to keep track of which version is the most up to date and stuff like that.

    Quote Originally Posted by Persist View Post
    but do not know what GitHub is, or how it could help in this situation.
    This is a GitHub repository. GitHub is designed to host source code and it has features to manage versioning.
    Treeview with NodeAdded/NodesRemoved events | BlinkLabel control | Calculate Permutations | Object Enums | ComboBox with centered items | .Net Internals article(not mine) | Wizard Control | Understanding Multi-Threading | Simple file compression | Demon Arena

    Copy/move files using Windows Shell | I'm not wanted

    C++ programmers will dismiss you as a cretinous simpleton for your inability to keep track of pointers chained 6 levels deep and Java programmers will pillory you for buying into the evils of Microsoft. Meanwhile C# programmers will get paid just a little bit more than you for writing exactly the same code and VB6 programmers will continue to whitter on about "footprints". - FunkyDexter

    There's just no reason to use garbage like InputBox. - jmcilhinney

    The threads I start are Niya and Olaf free zones. No arguing about the benefits of VB6 over .NET here please. Happiness must reign. - yereverluvinuncleber

  6. #6
    Hyperactive Member pourkascheff's Avatar
    Join Date
    Apr 2020
    Location
    LocalHost
    Posts
    384

    Re: Creating new versions of a VB program

    I used to backup my projects in rar files at the end of the day, naming the date. Therefore, I even access pre-previous versions in case a huge possible failures. simply close the VS, extract rar, replace them and focus on changes... I believe in GitHub's versioning but quitting old habits, kills me. Peace.

  7. #7
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: Creating new versions of a VB program

    You should be using some form of source control, be it GitHub or DevOps or something else. You may not use all the features available but it provides advantages for even the dinkiest of hobbyist developers.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

  8. #8
    Wall Poster TysonLPrice's Avatar
    Join Date
    Sep 2002
    Location
    Columbus, Ohio
    Posts
    3,969

    Re: Creating new versions of a VB program

    We have been using TortoiseSVN for years. It is free.

    https://tortoisesvn.net/
    Please remember next time...elections matter!

  9. #9
    PowerPoster PlausiblyDamp's Avatar
    Join Date
    Dec 2016
    Location
    Pontypool, Wales
    Posts
    2,958

    Re: Creating new versions of a VB program

    Modern versions of VS also have a lot of Git functionality built in these days, you can use Git purely local if you don't want to connect to something like GitHub or Azure DevOps

  10. #10

    Thread Starter
    Member
    Join Date
    Dec 2011
    Location
    Melbourne
    Posts
    37

    Re: Creating new versions of a VB program

    GitHub looks great. I am having difficulty getting it going so will post a separate query,
    Back to my original query. Is copying a folder, e.g., BankSim02 to BankSim03 likely to lead to problems and lost files due to some overwriting?
    thanks for your answers

  11. #11
    Super Moderator Shaggy Hiker's Avatar
    Join Date
    Aug 2002
    Location
    Idaho
    Posts
    40,104

    Re: Creating new versions of a VB program

    I would suggest looking at GitLab as well as GitHub. As the name suggests, they are both based on Git, but they have different pricing models. Both have a free version, just with different benefits. I prefer GitLab to GitHub for the free private repos.

    As to the question, copying one folder to a new folder will not lead to problems due to overwriting. The files aren't references to actual files, they are the files themselves, so if you copy them to a new folder, you get a new copy. No overwriting, no loss...from that source. However, some people have reported losing files with OneDrive. Whether this was a mistake on their part or something else is an open question. For my part, I found OneDrive to be annoying when working with multiple computers. I could never get it to behave exactly as I wanted. I wanted it to act as essentially a networked attached hard drive, with no more intelligence than that. A common storage area and nothing more. That's not what MS wants OneDrive to do. They want to do some automatic syncing, which doesn't work so well with multiple computers, because it isn't always clear.

    GitLab/GitHub works much better in that regard, though it's a much 'heavier' solution, considering all the bells and whistles. It's a version control system, not a simple storage system, and that's important. It does mean some simple tasks don't quite work as you might expect. You are creating a new version such that you can revert back to some earlier version, which requires more bookeeping. That is usually pretty simple for the user with either Git. It doesn't feel quite as simple with Azure DevOps. Integrating either into VS is super easy once you know how to do it. There's a modest learning curve for the basics, and a whole lot of potential beyond the basics, but once you get the basics, it's pretty easy.
    My usual boring signature: Nothing

  12. #12
    PowerPoster
    Join Date
    Feb 2012
    Location
    West Virginia
    Posts
    14,206

    Re: Creating new versions of a VB program

    Quote Originally Posted by Persist View Post
    GitHub looks great. I am having difficulty getting it going so will post a separate query,
    Back to my original query. Is copying a folder, e.g., BankSim02 to BankSim03 likely to lead to problems and lost files due to some overwriting?
    thanks for your answers
    For the most part no it should not lead to problems with over writing, provided of course that the source files are all in that folder tree and you are not linking to source files in some other location and of course you open the sln file that is now in the new location, all other code files are usually expected to be in a location relative to the sln location. If there is any doubt you can open the sln with notepad and see the path to the project file(s) and you ca open the project file(s) with note pad and see the path to any included source files and such so long as all those point to the current folder or a sub folder thereof then there should be no problem..

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