Hi


Hi
i am getting error when i try to run application on another PC
i create MDI Application with UniDAC, its running fine in where i developing , i try to run exe in another pc its giving me error,

UniConnection1 all fields are empty as well, if some one advice me what sould be the issue appriciate

please refer to the attach image

Comments

  1. no i have install SQL 2012 on that PC as well, i am creating UniDac for the
    connection, i use same Data units and and other units create blank project
    , that is run ok its asking to enter database details without any error.
    please check the link i have add those files in to dropbox, since mail not
    allowed to add big files. if you can tell me what is the issue . i made
    this application as MDI

    https://www.dropbox.com/sh/9y55yq21fuqoeln/AAC3gs89JIs4B1qNP-J1MQe7a?dl=0

    ReplyDelete
  2. I have taken a look at some of the code you enclosed. If I remember UniDAC correctly, it creates definition files for design time use and you can either uses these at run time, or provide your own parameters. There is a possibility that on the machine that does not work, the default connection parameters for your database are not being set as they are on the machine that works. Check what your development machine is actually using and make sure that you supply the same connection settings when running on a different PC.

    As a side-note, and feel free to ignore from this point forward if I am teaching Grandma to suck eggs, but why store DB login credentials in the registry? Personally, I would require that the user logs on to the database, or use domain based credentials. Storing DB passwords, whilst not necessarily the end of the world, should be handled carefully, if done at all. Naturally, it depends on the nature of the data being stored, but it's worth thinking about.

    Secondly, I accept that you may only be writing some test SQL and that this app may have been constructed to quickly demonstrate your issue, but please do consider using parameterised and prepared queries. You open yourself up to all sorts of potential issues if you construct queries as you are doing. Also, do consider separating UI code from DB code.

    ReplyDelete

Post a Comment