Results 1 to 4 of 4
  1. #1
    New Lounger
    Join Date
    May 2016
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Want to save value in the variables even after the application is closed in visual basic 6.0

    I am making a login page form for a project of mine and there is also a registration form in it so what basically I want to do is to store the different usernames and password stored by different people from registration form and use those to login I made a module but the information stored in an array in the module is temporary so is there a way to store the registration information into the rom permanently???

  2. #2
    Super Moderator RetiredGeek's Avatar
    Join Date
    Mar 2004
    Location
    Manning, South Carolina
    Posts
    9,436
    Thanks
    372
    Thanked 1,457 Times in 1,326 Posts
    Polar,

    Welcome to the Lounge as a new poster.

    First you can't store to ROM as that is Read Only Memory.

    What you'll need to do is to write all the information you want to preserve to a file. Since it is to be used later to verify logons, as I read your post, you'll need to store that file in a location, e.g. network drive, cloud drive, etc., that all your users will have access to.

    You'll also have to make your VB routine read that file first thing when it is started. Also once read you will want to close it so if another user needs to write to it it will be available, e.g. only keep it open the minimum time necessary to complete an operation Read/Write.

    HTH
    May the Forces of good computing be with you!

    RG

    PowerShell & VBA Rule!

    My Systems: Desktop Specs
    Laptop Specs

  3. #3
    New Lounger
    Join Date
    May 2016
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    so how do I do it???

    Quote Originally Posted by RetiredGeek View Post
    Polar,

    Welcome to the Lounge as a new poster.

    First you can't store to ROM as that is Read Only Memory.

    What you'll need to do is to write all the information you want to preserve to a file. Since it is to be used later to verify logons, as I read your post, you'll need to store that file in a location, e.g. network drive, cloud drive, etc., that all your users will have access to.

    You'll also have to make your VB routine read that file first thing when it is started. Also once read you will want to close it so if another user needs to write to it it will be available, e.g. only keep it open the minimum time necessary to complete an operation Read/Write.

    HTH
    thank you

    Then can you guide me of what kind of file should I be making?? like should it be a notepad file and if it is to be a notepad file then how do I store the value of the array in the notepad file I am very new so sorry for my little knowledge.

  4. #4
    Super Moderator RetiredGeek's Avatar
    Join Date
    Mar 2004
    Location
    Manning, South Carolina
    Posts
    9,436
    Thanks
    372
    Thanked 1,457 Times in 1,326 Posts
    Polar,

    Sorry but I can't offer further advice as I'm not a VB programmer nor do I have the tools to investigate the posibilities. I was answering the question from my general background in programming with other languages.

    My recommendation would be a database file of some kind. You should have a look at the dll references available in VB (I'm pretty sure there are ones for Access and/or SQL Databases or possibly Excel) with them you could create and populate a database/list w/o actually having Access and/or Excel.

    Perhaps some Lounge members with VB experience will chime in.

    BTW: Since this is about Visual Basic and NOT Visual Basic for Applications I'm moving the thread to Windows Programming.

    May the Forces of good computing be with you!

    RG

    PowerShell & VBA Rule!

    My Systems: Desktop Specs
    Laptop Specs

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •