1 Reply Latest reply on Jan 19, 2012 12:03 PM by philmodjunk

    Open a external database inserting login and password from a script

    RodrigoRabello

      Title

      Open a external database inserting login and password from a script

      Post

      Hi,

      I have a database that uses another external database and would like to open the external database by a script in the main database.

      However, the login and password need to be informed in the script as if they were parameters or other way by the script, can not be inserted by the User.

      Using the File Open command, I can not enter the login and password in the script, just by typing directly in the login window.

      Please, someone knows a way to do this

        • 1. Re: Open a external database inserting login and password from a script
          philmodjunk

          If both files have the same account name and password defined. Open File will open the second file with the same account name and password as the first.

          If this is not possible. Create a small "opener file" but keep it hidden from users to prevent it's use for unauthorized access. (Easy to do if files are hosted from a server by FileMaker Server or FileMaker Pro.)

          Define an account name and password in the opener file to match the desired account name and password in File 2. Use File Options to set the opener file to open itself automatically with this account name and password. Now write your open file script in the opener file and use Perform script from File 1 to perform the script in the opener file to get File 2 to open.