Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. Protecting text file in VB6

Protecting text file in VB6

Scheduled Pinned Locked Moved Visual Basic
help
4 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • H Offline
    H Offline
    hang_em
    wrote on last edited by
    #1

    I have this VB6 program which reads and retrieve information or data from a text file as needed. I need to protect this text file which hold my data, is there any way i can encrypt or compressed so that the program can only retrieve the data from the file in order to protect the data inside. Would be very grateful if anyone could help me on this. Thanks.

    D 1 Reply Last reply
    0
    • H hang_em

      I have this VB6 program which reads and retrieve information or data from a text file as needed. I need to protect this text file which hold my data, is there any way i can encrypt or compressed so that the program can only retrieve the data from the file in order to protect the data inside. Would be very grateful if anyone could help me on this. Thanks.

      D Offline
      D Offline
      Dave Kreskowiak
      wrote on last edited by
      #2

      You can encrypt/decrypt the text file, but you'd have to hold the contents of the file in memory to use it and modify it, then write it back out encrpyted. You can find a few examples in this list[^]. I highly recommend abandoning VB6 development and moving to VB.NET. Once you get past the learning curve, you'll find that you've been writing code in the Dark Ages.

      A guide to posting questions on CodeProject[^]
      Dave Kreskowiak

      H 1 Reply Last reply
      0
      • D Dave Kreskowiak

        You can encrypt/decrypt the text file, but you'd have to hold the contents of the file in memory to use it and modify it, then write it back out encrpyted. You can find a few examples in this list[^]. I highly recommend abandoning VB6 development and moving to VB.NET. Once you get past the learning curve, you'll find that you've been writing code in the Dark Ages.

        A guide to posting questions on CodeProject[^]
        Dave Kreskowiak

        H Offline
        H Offline
        hang_em
        wrote on last edited by
        #3

        Thanks for the response, but the link mention just open the google page. Well my problem is like i have developed this software which use a text file to hold the data, this text data i need to protect like we made a protection in ms-access using password. I dont' want the user to make changes or directly access the text file but through the software only and only read the data. Is there any way I can encrypt or compressed the text file and open the file through the program while using it. I would be grateful if you could show me how to do this. Thanks.

        D 1 Reply Last reply
        0
        • H hang_em

          Thanks for the response, but the link mention just open the google page. Well my problem is like i have developed this software which use a text file to hold the data, this text data i need to protect like we made a protection in ms-access using password. I dont' want the user to make changes or directly access the text file but through the software only and only read the data. Is there any way I can encrypt or compressed the text file and open the file through the program while using it. I would be grateful if you could show me how to do this. Thanks.

          D Offline
          D Offline
          Dave Kreskowiak
          wrote on last edited by
          #4

          hang_em wrote:

          but the link mention just open the google page.

          Yeah, this is where you start your own research and start following those links and reading what they bring up. You will also find examples with some of them. I don't have any examples to give you because I abandoned all VB6 developement, in favor of VB.NET, about 9 years ago.

          A guide to posting questions on CodeProject[^]
          Dave Kreskowiak

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups