Forms (PL/SQL?) Question

From: Peter Bruhn <lbruhn_at_miss.wu-wien.ac.at>
Date: Mon, 2 Sep 2002 07:26:47 +0000 (UTC)
Message-ID: <akv3rn$vb3$1_at_bird.wu-wien.ac.at>


Hi,

I am having a forms (pl/sql) question that I have already posed here. But having gotten no response, I will try to rephrase it in more detail.

I have two distinct forms application that are basically the same. Both applications consist of many forms. The difference between the applications is that the first one works with a frozen database containing data until the introduction of the euro in our local currency, the austrian shilling. The second application works with our current production database in euro. Lets call the two applications the ats-application and the euro-application.

The ats-application has its forms in a directory say c:\ats and the euro-application in a directory c:\euro. Now I have a form that is a common entry point for the two applications. This form is located in c:\euro and has two buttons to start either the ats- or the euro-application. Now there is no problem when starting the euro-application since the current directory is c:\euro and all .fmx and .mmx files are taken from this directory. But when starting the ats-application (via new_form('c:\ats\...',...)) the current directory remains c:\euro and so e.g. the wrong menu-files are loaded (there are different menus in the ats- and euro-application having the same name, differing in the directory, where they are located).

Being not a forms expert a couple of questions arise to me:

  1. In what order does the forms run_time look for forms and menu-files, if no absolut path is given? My guess is, it looks in the present working directory and then in some environment variable (which name I do not know).
  2. Is there a way to change the present working directory within pl/sql? Being a UNIX-guy I dont even know in which environment-variable the present working directory is found under Windows NT.
  3. Can I change the content of an environment variable in pl/sql? I only know of env.getvar(). As there is no putvar() in the env package I am a bit pessimistic about this.
  4. Is there any solution besides changing all forms to use absolut path names or recode all forms so the file names between the two applications are distinct? Hmmm, writing all this, an idea comes into my mind: could I use the host-command (or dde.app_begin) to start a complete new forms-runtime with the correct environment? But still I would prefer to find a way to change the working directory and stay within the same instance of my forms runtime.

Thanks for any hints, comments, flames,.... Peter (bruhn_at_wu-wien.ac.at) Received on Mon Sep 02 2002 - 09:26:47 CEST

Original text of this message