Results 1 to 3 of 3

Thread: Installing a database with an application

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Nov 2000
    Posts
    22
    Hello everybody,
    I'm pretty new in vb programming so these are my important questions:
    I developed a database-based application and now I have to create a setup/install package. I used ADO to access my database and the connection string uses a dsn name instead of a filename. So, my setup program should create a user dsn on the destination machine after the program has been installed and link that dsn to the database (created with access) in the application path. How can i do this? is there an easier way to export a database in the final package and make the program still work (it still finds the database path)?
    Question 2: How can i hide, or crypt my database in the final distribution and make it not-accessible with programs like Access?
    Thank you very much for your help. Your site is simply the best. Bye


  2. #2
    Addicted Member ender_pete's Avatar
    Join Date
    Aug 2000
    Location
    Virginia, United States
    Posts
    131

    Wink

    to make the package the simplest way is to use the package and deploy wizard that comes with vb, it helps you detect the files you need and then you can add anymore that it didn't detect. its pretty simple to use so you shouldn't have a problem.

    now as to encrypting the database, the best answer i can give you is to put user security on the database and encrypt your data..

    now to encrypt your data you just need to add either a
    activex encryption tool or write a encryption algorithim..
    but since your new to vb your best bet is o find an activex control to do it for you... then even if your users break into the database they can't read the data because its encrypted itself and the don't have the key to decrypt it...


    if you want to know where to find a control go out to cnet or lycos or anywhere that stores free file/utilities and you can probably find one in the programming section...
    i put controls i write out there to benefit any other programmer who could use them.... so you don't have to pay for something you could have wrote yourself...
    ender_pete
    C#,VS.NET Ent Arch, vb6 ee sp5,html,vbscript,jscript,
    xml,dhtml,delphi,c++,vc++,java,cgi,php, python, ada(so ancient) ,adasage(also ancient) and others i can't remember.....

  3. #3
    Randalf the Red honeybee's Avatar
    Join Date
    Jun 2000
    Location
    off others' brains
    Posts
    4,345

    Well ...

    If you are using ADO, there is no need to use DSN to access your database. Because then you would have to create the DSN on the client's machine.

    Use a DSN-less ADO connection. It works with virtually every database type. This will eliminate the need to write the routine to create a DSN.

    Secondly, if you are going to put the database in the same folder as the application, i.e. in the AppPath, when you create a package for your application, include the database file (possible only if it is Access) in the files to be distributed with your application and set the destination directory for the database file as 'AppPath'.

    Otherwise, include a routine in your code to create the database at the 'AppPath' location.


    I am not a complete idiot. Some parts are still missing.
    Check out the rtf-help tutorial
    General VB Faq Thread
    Change is the only constant thing. I have not changed my signature in a long while and now it has started to stink!
    Get more power for your floppy disks. ; View honeybee's Elite Club:
    Use meaningfull thread titles. And add "[Resolved]" in the thread title when you have got a satisfactory response.
    And if that response was mine, please think about giving me a rep. I like to collect them!

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