PDA

View Full Version : BDE ALIAS NEED WORK-AROUND !!

NewsArchive
07-06-1997, 12:00 AM
I am have the same trouble like everybody else with isx 2.
The installprogram will not create my aliases! Is there a work-around ?
if so, please tell. And i experienced another problem: after installing
on nt 4.0
i can not run the bde-config util to set the alias manual ?!? Any
suggestions ?

Tom de Kuijper

NewsArchive
09-11-1997, 12:00 AM
On Sun, 06 Jul 1997 06:33:59 +0200, Tom de Kuijper <kuijper@tref.nl> wrote:
>I am have the same trouble like everybody else with isx 2.
>The installprogram will not create my aliases! Is there a work-around ?

What type of Alias is it? If it is a SQL Server type, please insert the
<INSTALLDIR> parameter into the path box. If not, make sure the ALIAS is
not on the machine you are testing on. Make sure that it is a FULL BDE
installation you put on...

Stefan
ellipse data systems

NewsArchive
01-14-2000, 01:00 AM
Steve

Thanks for your help. The driver type is MSACCESS so the parameter is Database
Name. I tried putting <TARGETDIR>\xxx.mdb as the argument. After installation
this results in the BDE parameter still being <TARGETDIR>\xxx.mdb.

So I changed the argument in the BDE parameter to <TARGETDB> and in
ProgramFiles_Installing I put the following code:
set oObj = GetObject("New BDE 5.1 1");
MessageBox ("Getting BDE object",INFORMATION);

endif;
szDir = TARGETDIR ^ "xxx.mdb";
oObj.ScriptDefinedVar("<TARGETDB>") = szDir;

The message appears but the BDE parameter is still <TARGETDB>. How can I force
the substitution?

Andrew

Stephen Downard wrote:

> Andrew,
> When inserting the BDE object into your project the BDE wizard will
> execute. Select the Alias name and then modify it's parameters. You will
> want to select the PATH parameter and specify <TARGETDIR>. Once you have
> edited the PATH parameter make sure that you click the combo box control to
> insert the modified item back into the combo list. Then rebuild your
> project. If you specify a script defined folder to represent the target
> path you will need to use the BDE's method ScriptDefinedVar( ) to assign the
> target path to the variable. Please refer to the BDE help docs located in
> the Object Gallery.
>
> Thanks,
> -Steve
>
> "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> news:387DA89D.646F1750@nsw.bigpond.net.au...
> > Hi
> >
> > My installation requires that the BDE Alias points to a different
> > directory on the target machine than the development machine. At present
> > Installshield Professional 6 uses the development machine's Alias
> > configuration. How can I change the directory to the target directory?
> >
> > Thanks
> >
> > Andrew
> >

NewsArchive
01-14-2000, 01:00 AM
Andrew,
The error in the code is located in the call to ScriptDefinedVar( ).
Please remove the inequality signs from the parameter expression.

oObj.ScriptDefinedVar("TARGETDB") = szDir;

This should solve your problem. I believe this is a documentation error.

Thanks,
Steve

"Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
news:387E9106.58D5969A@nsw.bigpond.net.au...
> Steve
>
> Thanks for your help. The driver type is MSACCESS so the parameter is
Database
> Name. I tried putting <TARGETDIR>\xxx.mdb as the argument. After
installation
> this results in the BDE parameter still being <TARGETDIR>\xxx.mdb.
>
> So I changed the argument in the BDE parameter to <TARGETDB> and in
> ProgramFiles_Installing I put the following code:
> set oObj = GetObject("New BDE 5.1 1");
> MessageBox ("Getting BDE object",INFORMATION);
>
> endif;
> szDir = TARGETDIR ^ "xxx.mdb";
> oObj.ScriptDefinedVar("<TARGETDB>") = szDir;
>
> The message appears but the BDE parameter is still <TARGETDB>. How can I
force
> the substitution?
>
> Andrew
>
> Stephen Downard wrote:
>
> > Andrew,
> > When inserting the BDE object into your project the BDE wizard will
> > execute. Select the Alias name and then modify it's parameters. You
will
> > want to select the PATH parameter and specify <TARGETDIR>. Once you
have
> > edited the PATH parameter make sure that you click the combo box control
to
> > insert the modified item back into the combo list. Then rebuild your
> > project. If you specify a script defined folder to represent the target
> > path you will need to use the BDE's method ScriptDefinedVar( ) to assign
the
> > target path to the variable. Please refer to the BDE help docs located
in
> > the Object Gallery.
> >
> > Thanks,
> > -Steve
> >
> > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> > news:387DA89D.646F1750@nsw.bigpond.net.au...
> > > Hi
> > >
> > > My installation requires that the BDE Alias points to a different
> > > directory on the target machine than the development machine. At
present
> > > Installshield Professional 6 uses the development machine's Alias
> > > configuration. How can I change the directory to the target directory?
> > >
> > > Thanks
> > >
> > > Andrew
> > >
>

NewsArchive
01-14-2000, 01:00 AM
Actually this is not a documentation issue the concern is with how I have
implemented the method ScriptDefinedVar. End-users should use the angle
brackets within the parameter expression when passing into the method
ScriptDefinedVar. This is consistent with the implementation of all other
objects. I use this method to perform assignments for two different cases.
The first, to assign an end-user specified target location for the BDEDIR
and for script defined folders specified in the persisted data. The
persisted data is the data the end-user has stored via the BDE Wizard.
For now use the implementation that I had suggested and I will update the
object to handle all cases.

-Steve

"Stephen Downard" <stephen@installshield.com> wrote in message
news:387f677f.0@news.installshield.com...
> Andrew,
> The error in the code is located in the call to ScriptDefinedVar( ).
> Please remove the inequality signs from the parameter expression.
>
> oObj.ScriptDefinedVar("TARGETDB") = szDir;
>
> This should solve your problem. I believe this is a documentation error.
>
> Thanks,
> Steve
>
> "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> news:387E9106.58D5969A@nsw.bigpond.net.au...
> > Steve
> >
> > Thanks for your help. The driver type is MSACCESS so the parameter is
> Database
> > Name. I tried putting <TARGETDIR>\xxx.mdb as the argument. After
> installation
> > this results in the BDE parameter still being <TARGETDIR>\xxx.mdb.
> >
> > So I changed the argument in the BDE parameter to <TARGETDB> and in
> > ProgramFiles_Installing I put the following code:
> > set oObj = GetObject("New BDE 5.1 1");
> > MessageBox ("Getting BDE object",INFORMATION);
> >
> > endif;
> > szDir = TARGETDIR ^ "xxx.mdb";
> > oObj.ScriptDefinedVar("<TARGETDB>") = szDir;
> >
> > The message appears but the BDE parameter is still <TARGETDB>. How can I
> force
> > the substitution?
> >
> > Andrew
> >
> > Stephen Downard wrote:
> >
> > > Andrew,
> > > When inserting the BDE object into your project the BDE wizard
will
> > > execute. Select the Alias name and then modify it's parameters. You
> will
> > > want to select the PATH parameter and specify <TARGETDIR>. Once you
> have
> > > edited the PATH parameter make sure that you click the combo box
control
> to
> > > insert the modified item back into the combo list. Then rebuild your
> > > project. If you specify a script defined folder to represent the
target
> > > path you will need to use the BDE's method ScriptDefinedVar( ) to
assign
> the
> > > target path to the variable. Please refer to the BDE help docs
located
> in
> > > the Object Gallery.
> > >
> > > Thanks,
> > > -Steve
> > >
> > > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> > > news:387DA89D.646F1750@nsw.bigpond.net.au...
> > > > Hi
> > > >
> > > > My installation requires that the BDE Alias points to a different
> > > > directory on the target machine than the development machine. At
> present
> > > > Installshield Professional 6 uses the development machine's Alias
> > > > configuration. How can I change the directory to the target
directory?
> > > >
> > > > Thanks
> > > >
> > > > Andrew
> > > >
> >
>
>

NewsArchive
01-14-2000, 01:00 AM
To clarify:

To assign a value to the <BDEDIR>(only if the script defined folder is not
persisted) use the following implementation:

To assign a value to a <scriptdefinedfolder> that is persisted(via the BDE
Wizard) use the following implementation:
-This is because internally within the BDE object code I use the object
TextSub.Substitue to replace the literal string that contains the script
defined folder. So the method Substitute() should automatically replace
this variable with the assigned value and concatenate it to the literal
string.

The implementation here is reverse of what you would actually expect.
TextSub.Substitue requires the literal expression to contain the angle
brackets and TextSub.Value is indifferent. Using TextSub.Value the
expression can contain the brackets or not; internally we remove the angle
brackets anyway when using TextSub.Value. To be specific the object method
ScriptDefinedVar( ) calls TextSub.Value and this is what is exposed to
end-users. So in the BDE object end-users assign their values to script
defined folders using this method but in the case of persisted data I use
TextSub.Substitute(only BDE Object).

In future update always use the angle brackets. This issue is only related
to the BDE Object.

-Steve

"Stephen Downard" <stephen@installshield.com> wrote in message
news:387f7773.0@news.installshield.com...
> Actually this is not a documentation issue the concern is with how I have
> implemented the method ScriptDefinedVar. End-users should use the angle
> brackets within the parameter expression when passing into the method
> ScriptDefinedVar. This is consistent with the implementation of all other
> objects. I use this method to perform assignments for two different
cases.
> The first, to assign an end-user specified target location for the BDEDIR
> and for script defined folders specified in the persisted data. The
> persisted data is the data the end-user has stored via the BDE Wizard.
> For now use the implementation that I had suggested and I will update the
> object to handle all cases.
>
> -Steve
>
>
> "Stephen Downard" <stephen@installshield.com> wrote in message
> news:387f677f.0@news.installshield.com...
> > Andrew,
> > The error in the code is located in the call to ScriptDefinedVar( ).
> > Please remove the inequality signs from the parameter expression.
> >
> > oObj.ScriptDefinedVar("TARGETDB") = szDir;
> >
> > This should solve your problem. I believe this is a documentation
error.
> >
> > Thanks,
> > Steve
> >
> > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> > news:387E9106.58D5969A@nsw.bigpond.net.au...
> > > Steve
> > >
> > > Thanks for your help. The driver type is MSACCESS so the parameter is
> > Database
> > > Name. I tried putting <TARGETDIR>\xxx.mdb as the argument. After
> > installation
> > > this results in the BDE parameter still being <TARGETDIR>\xxx.mdb.
> > >
> > > So I changed the argument in the BDE parameter to <TARGETDB> and in
> > > ProgramFiles_Installing I put the following code:
> > > set oObj = GetObject("New BDE 5.1 1");
> > > MessageBox ("Getting BDE object",INFORMATION);
> > >
> > > endif;
> > > szDir = TARGETDIR ^ "xxx.mdb";
> > > oObj.ScriptDefinedVar("<TARGETDB>") = szDir;
> > >
> > > The message appears but the BDE parameter is still <TARGETDB>. How can
I
> > force
> > > the substitution?
> > >
> > > Andrew
> > >
> > > Stephen Downard wrote:
> > >
> > > > Andrew,
> > > > When inserting the BDE object into your project the BDE wizard
> will
> > > > execute. Select the Alias name and then modify it's parameters.
You
> > will
> > > > want to select the PATH parameter and specify <TARGETDIR>. Once you
> > have
> > > > edited the PATH parameter make sure that you click the combo box
> control
> > to
> > > > insert the modified item back into the combo list. Then rebuild
your
> > > > project. If you specify a script defined folder to represent the
> target
> > > > path you will need to use the BDE's method ScriptDefinedVar( ) to
> assign
> > the
> > > > target path to the variable. Please refer to the BDE help docs
> located
> > in
> > > > the Object Gallery.
> > > >
> > > > Thanks,
> > > > -Steve
> > > >
> > > > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> > > > news:387DA89D.646F1750@nsw.bigpond.net.au...
> > > > > Hi
> > > > >
> > > > > My installation requires that the BDE Alias points to a different
> > > > > directory on the target machine than the development machine. At
> > present
> > > > > Installshield Professional 6 uses the development machine's Alias
> > > > > configuration. How can I change the directory to the target
> directory?
> > > > >
> > > > > Thanks
> > > > >
> > > > > Andrew
> > > > >
> > >
> >
> >
>
>

NewsArchive
01-17-2000, 01:00 AM
Steve

I am not able to make the program substitute the correct value. In the BDE
object the Database name is listed as <TARGETDB>. In the script I use
oObj.ScriptDefinedVar("TARGETDB") = szDir. MessageBox shows that the szDir is
the correct value. After installation BDE administrator lists the "database
name" as whatever was initially set in the BDE object. Below is the code I am
using:

function ProgramFiles_Installing()
/* Need an object variable to hold a reference to the object. */
OBJECT oObj;
STRING szDir;
begin
/* Get a reference to an BDE 5.1 object named "New BDE 5.1 Object 1". */
set oObj = GetObject("New BDE 5.1 1");
if oObj.Status.Number != OBJ_STATUS_SUCCESS then
MessageBox ( oObj.Status.Description, SEVERE );
abort;
endif;
szDir = TARGETDIR ^ "xxx.mdb";
MessageBox (szDir,INFORMATION);
oObj.ScriptDefinedVar("TARGETDB") = szDir;
end;

Andrew

Stephen Downard wrote:

> To clarify:
>
> To assign a value to the <BDEDIR>(only if the script defined folder is not
> persisted) use the following implementation:
>
> To assign a value to a <scriptdefinedfolder> that is persisted(via the BDE
> Wizard) use the following implementation:
> -This is because internally within the BDE object code I use the object
> TextSub.Substitue to replace the literal string that contains the script
> defined folder. So the method Substitute() should automatically replace
> this variable with the assigned value and concatenate it to the literal
> string.
>
> The implementation here is reverse of what you would actually expect.
> TextSub.Substitue requires the literal expression to contain the angle
> brackets and TextSub.Value is indifferent. Using TextSub.Value the
> expression can contain the brackets or not; internally we remove the angle
> brackets anyway when using TextSub.Value. To be specific the object method
> ScriptDefinedVar( ) calls TextSub.Value and this is what is exposed to
> end-users. So in the BDE object end-users assign their values to script
> defined folders using this method but in the case of persisted data I use
> TextSub.Substitute(only BDE Object).
>
> In future update always use the angle brackets. This issue is only related
> to the BDE Object.
>
> -Steve
>
> "Stephen Downard" <stephen@installshield.com> wrote in message
> news:387f7773.0@news.installshield.com...
> > Actually this is not a documentation issue the concern is with how I have
> > implemented the method ScriptDefinedVar. End-users should use the angle
> > brackets within the parameter expression when passing into the method
> > ScriptDefinedVar. This is consistent with the implementation of all other
> > objects. I use this method to perform assignments for two different
> cases.
> > The first, to assign an end-user specified target location for the BDEDIR
> > and for script defined folders specified in the persisted data. The
> > persisted data is the data the end-user has stored via the BDE Wizard.
> > For now use the implementation that I had suggested and I will update the
> > object to handle all cases.
> >
> > -Steve
> >
> >
> > "Stephen Downard" <stephen@installshield.com> wrote in message
> > news:387f677f.0@news.installshield.com...
> > > Andrew,
> > > The error in the code is located in the call to ScriptDefinedVar( ).
> > > Please remove the inequality signs from the parameter expression.
> > >
> > > oObj.ScriptDefinedVar("TARGETDB") = szDir;
> > >
> > > This should solve your problem. I believe this is a documentation
> error.
> > >
> > > Thanks,
> > > Steve
> > >
> > > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> > > news:387E9106.58D5969A@nsw.bigpond.net.au...
> > > > Steve
> > > >
> > > > Thanks for your help. The driver type is MSACCESS so the parameter is
> > > Database
> > > > Name. I tried putting <TARGETDIR>\xxx.mdb as the argument. After
> > > installation
> > > > this results in the BDE parameter still being <TARGETDIR>\xxx.mdb.
> > > >
> > > > So I changed the argument in the BDE parameter to <TARGETDB> and in
> > > > ProgramFiles_Installing I put the following code:
> > > > set oObj = GetObject("New BDE 5.1 1");
> > > > MessageBox ("Getting BDE object",INFORMATION);
> > > >
> > > > endif;
> > > > szDir = TARGETDIR ^ "xxx.mdb";
> > > > oObj.ScriptDefinedVar("<TARGETDB>") = szDir;
> > > >
> > > > The message appears but the BDE parameter is still <TARGETDB>. How can
> I
> > > force
> > > > the substitution?
> > > >
> > > > Andrew
> > > >
> > > > Stephen Downard wrote:
> > > >
> > > > > Andrew,
> > > > > When inserting the BDE object into your project the BDE wizard
> > will
> > > > > execute. Select the Alias name and then modify it's parameters.
> You
> > > will
> > > > > want to select the PATH parameter and specify <TARGETDIR>. Once you
> > > have
> > > > > edited the PATH parameter make sure that you click the combo box
> > control
> > > to
> > > > > insert the modified item back into the combo list. Then rebuild
> your
> > > > > project. If you specify a script defined folder to represent the
> > target
> > > > > path you will need to use the BDE's method ScriptDefinedVar( ) to
> > assign
> > > the
> > > > > target path to the variable. Please refer to the BDE help docs
> > located
> > > in
> > > > > the Object Gallery.
> > > > >
> > > > > Thanks,
> > > > > -Steve
> > > > >
> > > > > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> > > > > news:387DA89D.646F1750@nsw.bigpond.net.au...
> > > > > > Hi
> > > > > >
> > > > > > My installation requires that the BDE Alias points to a different
> > > > > > directory on the target machine than the development machine. At
> > > present
> > > > > > Installshield Professional 6 uses the development machine's Alias
> > > > > > configuration. How can I change the directory to the target
> > directory?
> > > > > >
> > > > > > Thanks
> > > > > >
> > > > > > Andrew
> > > > > >
> > > >
> > >
> > >
> >
> >

NewsArchive
01-17-2000, 01:00 AM
Andrew,
Try implementing your code in the OnMoving() event to see if that makes a
difference.

"Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
news:3882406B.5522C879@nsw.bigpond.net.au...
> Steve
>
> I am not able to make the program substitute the correct value. In the BDE
> object the Database name is listed as <TARGETDB>. In the script I use
> oObj.ScriptDefinedVar("TARGETDB") = szDir. MessageBox shows that the
szDir is
> the correct value. After installation BDE administrator lists the
"database
> name" as whatever was initially set in the BDE object. Below is the code I
am
> using:
>
> function ProgramFiles_Installing()
> /* Need an object variable to hold a reference to the object. */
> OBJECT oObj;
> STRING szDir;
> begin
> /* Get a reference to an BDE 5.1 object named "New BDE 5.1 Object 1".
*/
> set oObj = GetObject("New BDE 5.1 1");
> if oObj.Status.Number != OBJ_STATUS_SUCCESS then
> MessageBox ( oObj.Status.Description, SEVERE );
> abort;
> endif;
> szDir = TARGETDIR ^ "xxx.mdb";
> MessageBox (szDir,INFORMATION);
> oObj.ScriptDefinedVar("TARGETDB") = szDir;
> end;
>
> Andrew
>
> Stephen Downard wrote:
>
> > To clarify:
> >
> > To assign a value to the <BDEDIR>(only if the script defined folder is
not
> > persisted) use the following implementation:
> > oObj.ScriptDefinedVar("<BDEDIR>") = "your path";
> >
> > To assign a value to a <scriptdefinedfolder> that is persisted(via the
BDE
> > Wizard) use the following implementation:
> > oObj.ScriptDefinedVar("scriptdefinedfolder") = "your path";
> > -This is because internally within the BDE object code I use the object
> > TextSub.Substitue to replace the literal string that contains the script
> > defined folder. So the method Substitute() should automatically replace
> > this variable with the assigned value and concatenate it to the literal
> > string.
> >
> > The implementation here is reverse of what you would actually expect.
> > TextSub.Substitue requires the literal expression to contain the angle
> > brackets and TextSub.Value is indifferent. Using TextSub.Value the
> > expression can contain the brackets or not; internally we remove the
angle
> > brackets anyway when using TextSub.Value. To be specific the object
method
> > ScriptDefinedVar( ) calls TextSub.Value and this is what is exposed to
> > end-users. So in the BDE object end-users assign their values to script
> > defined folders using this method but in the case of persisted data I
use
> > TextSub.Substitute(only BDE Object).
> >
> > In future update always use the angle brackets. This issue is only
related
> > to the BDE Object.
> >
> > -Steve
> >
> > "Stephen Downard" <stephen@installshield.com> wrote in message
> > news:387f7773.0@news.installshield.com...
> > > Actually this is not a documentation issue the concern is with how I
have
> > > implemented the method ScriptDefinedVar. End-users should use the
angle
> > > brackets within the parameter expression when passing into the method
> > > ScriptDefinedVar. This is consistent with the implementation of all
other
> > > objects. I use this method to perform assignments for two different
> > cases.
> > > The first, to assign an end-user specified target location for the
BDEDIR
> > > and for script defined folders specified in the persisted data. The
> > > persisted data is the data the end-user has stored via the BDE Wizard.
> > > For now use the implementation that I had suggested and I will update
the
> > > object to handle all cases.
> > >
> > > -Steve
> > >
> > >
> > > "Stephen Downard" <stephen@installshield.com> wrote in message
> > > news:387f677f.0@news.installshield.com...
> > > > Andrew,
> > > > The error in the code is located in the call to
ScriptDefinedVar( ).
> > > > Please remove the inequality signs from the parameter expression.
> > > >
> > > > oObj.ScriptDefinedVar("TARGETDB") = szDir;
> > > >
> > > > This should solve your problem. I believe this is a documentation
> > error.
> > > >
> > > > Thanks,
> > > > Steve
> > > >
> > > > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> > > > news:387E9106.58D5969A@nsw.bigpond.net.au...
> > > > > Steve
> > > > >
> > > > > Thanks for your help. The driver type is MSACCESS so the parameter
is
> > > > Database
> > > > > Name. I tried putting <TARGETDIR>\xxx.mdb as the argument. After
> > > > installation
> > > > > this results in the BDE parameter still being <TARGETDIR>\xxx.mdb.
> > > > >
> > > > > So I changed the argument in the BDE parameter to <TARGETDB> and
in
> > > > > ProgramFiles_Installing I put the following code:
> > > > > set oObj = GetObject("New BDE 5.1 1");
> > > > > MessageBox ("Getting BDE object",INFORMATION);
> > > > >
> > > > > endif;
> > > > > szDir = TARGETDIR ^ "xxx.mdb";
> > > > > oObj.ScriptDefinedVar("<TARGETDB>") = szDir;
> > > > >
> > > > > The message appears but the BDE parameter is still <TARGETDB>. How
can
> > I
> > > > force
> > > > > the substitution?
> > > > >
> > > > > Andrew
> > > > >
> > > > > Stephen Downard wrote:
> > > > >
> > > > > > Andrew,
> > > > > > When inserting the BDE object into your project the BDE
wizard
> > > will
> > > > > > execute. Select the Alias name and then modify it's parameters.
> > You
> > > > will
> > > > > > want to select the PATH parameter and specify <TARGETDIR>. Once
you
> > > > have
> > > > > > edited the PATH parameter make sure that you click the combo box
> > > control
> > > > to
> > > > > > insert the modified item back into the combo list. Then rebuild
> > your
> > > > > > project. If you specify a script defined folder to represent
the
> > > target
> > > > > > path you will need to use the BDE's method ScriptDefinedVar( )
to
> > > assign
> > > > the
> > > > > > target path to the variable. Please refer to the BDE help docs
> > > located
> > > > in
> > > > > > the Object Gallery.
> > > > > >
> > > > > > Thanks,
> > > > > > -Steve
> > > > > >
> > > > > > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> > > > > > news:387DA89D.646F1750@nsw.bigpond.net.au...
> > > > > > > Hi
> > > > > > >
> > > > > > > My installation requires that the BDE Alias points to a
different
> > > > > > > directory on the target machine than the development machine.
At
> > > > present
> > > > > > > Installshield Professional 6 uses the development machine's
Alias
> > > > > > > configuration. How can I change the directory to the target
> > > directory?
> > > > > > >
> > > > > > > Thanks
> > > > > > >
> > > > > > > Andrew
> > > > > > >
> > > > >
> > > >
> > > >
> > >
> > >
>

NewsArchive
01-17-2000, 01:00 AM
This may be a broken feature. I've also failed to set an alias with a script
defined variable. I've tried this code fragment in several events including
BDE_Installing.

Have you requested support from IS yet?

--
Steven S. Weston (sweston@westonmuir.com)
Weston & Muir (http://www.westonmuir.com)
The Banking Software Specialists
800-487-5655

NewsArchive
01-18-2000, 01:00 AM
Steve

Thanks for your help so far. But no luck with putting the code in OnMoving().

Andrew

Stephen Downard wrote:

> Andrew,
> Try implementing your code in the OnMoving() event to see if that makes a
> difference.
>
> "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> news:3882406B.5522C879@nsw.bigpond.net.au...
> > Steve
> >
> > I am not able to make the program substitute the correct value. In the BDE
> > object the Database name is listed as <TARGETDB>. In the script I use
> > oObj.ScriptDefinedVar("TARGETDB") = szDir. MessageBox shows that the
> szDir is
> > the correct value. After installation BDE administrator lists the
> "database
> > name" as whatever was initially set in the BDE object. Below is the code I
> am
> > using:
> >
> > function ProgramFiles_Installing()
> > /* Need an object variable to hold a reference to the object. */
> > OBJECT oObj;
> > STRING szDir;
> > begin
> > /* Get a reference to an BDE 5.1 object named "New BDE 5.1 Object 1".
> */
> > set oObj = GetObject("New BDE 5.1 1");
> > if oObj.Status.Number != OBJ_STATUS_SUCCESS then
> > MessageBox ( oObj.Status.Description, SEVERE );
> > abort;
> > endif;
> > szDir = TARGETDIR ^ "xxx.mdb";
> > MessageBox (szDir,INFORMATION);
> > oObj.ScriptDefinedVar("TARGETDB") = szDir;
> > end;
> >
> > Andrew
> >
> > Stephen Downard wrote:
> >
> > > To clarify:
> > >
> > > To assign a value to the <BDEDIR>(only if the script defined folder is
> not
> > > persisted) use the following implementation:
> > > oObj.ScriptDefinedVar("<BDEDIR>") = "your path";
> > >
> > > To assign a value to a <scriptdefinedfolder> that is persisted(via the
> BDE
> > > Wizard) use the following implementation:
> > > oObj.ScriptDefinedVar("scriptdefinedfolder") = "your path";
> > > -This is because internally within the BDE object code I use the object
> > > TextSub.Substitue to replace the literal string that contains the script
> > > defined folder. So the method Substitute() should automatically replace
> > > this variable with the assigned value and concatenate it to the literal
> > > string.
> > >
> > > The implementation here is reverse of what you would actually expect.
> > > TextSub.Substitue requires the literal expression to contain the angle
> > > brackets and TextSub.Value is indifferent. Using TextSub.Value the
> > > expression can contain the brackets or not; internally we remove the
> angle
> > > brackets anyway when using TextSub.Value. To be specific the object
> method
> > > ScriptDefinedVar( ) calls TextSub.Value and this is what is exposed to
> > > end-users. So in the BDE object end-users assign their values to script
> > > defined folders using this method but in the case of persisted data I
> use
> > > TextSub.Substitute(only BDE Object).
> > >
> > > In future update always use the angle brackets. This issue is only
> related
> > > to the BDE Object.
> > >
> > > -Steve
> > >
> > > "Stephen Downard" <stephen@installshield.com> wrote in message
> > > news:387f7773.0@news.installshield.com...
> > > > Actually this is not a documentation issue the concern is with how I
> have
> > > > implemented the method ScriptDefinedVar. End-users should use the
> angle
> > > > brackets within the parameter expression when passing into the method
> > > > ScriptDefinedVar. This is consistent with the implementation of all
> other
> > > > objects. I use this method to perform assignments for two different
> > > cases.
> > > > The first, to assign an end-user specified target location for the
> BDEDIR
> > > > and for script defined folders specified in the persisted data. The
> > > > persisted data is the data the end-user has stored via the BDE Wizard.
> > > > For now use the implementation that I had suggested and I will update
> the
> > > > object to handle all cases.
> > > >
> > > > -Steve
> > > >
> > > >
> > > > "Stephen Downard" <stephen@installshield.com> wrote in message
> > > > news:387f677f.0@news.installshield.com...
> > > > > Andrew,
> > > > > The error in the code is located in the call to
> ScriptDefinedVar( ).
> > > > > Please remove the inequality signs from the parameter expression.
> > > > >
> > > > > oObj.ScriptDefinedVar("TARGETDB") = szDir;
> > > > >
> > > > > This should solve your problem. I believe this is a documentation
> > > error.
> > > > >
> > > > > Thanks,
> > > > > Steve
> > > > >
> > > > > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> > > > > news:387E9106.58D5969A@nsw.bigpond.net.au...
> > > > > > Steve
> > > > > >
> > > > > > Thanks for your help. The driver type is MSACCESS so the parameter
> is
> > > > > Database
> > > > > > Name. I tried putting <TARGETDIR>\xxx.mdb as the argument. After
> > > > > installation
> > > > > > this results in the BDE parameter still being <TARGETDIR>\xxx.mdb.
> > > > > >
> > > > > > So I changed the argument in the BDE parameter to <TARGETDB> and
> in
> > > > > > ProgramFiles_Installing I put the following code:
> > > > > > set oObj = GetObject("New BDE 5.1 1");
> > > > > > MessageBox ("Getting BDE object",INFORMATION);
> > > > > >
> > > > > > endif;
> > > > > > szDir = TARGETDIR ^ "xxx.mdb";
> > > > > > oObj.ScriptDefinedVar("<TARGETDB>") = szDir;
> > > > > >
> > > > > > The message appears but the BDE parameter is still <TARGETDB>. How
> can
> > > I
> > > > > force
> > > > > > the substitution?
> > > > > >
> > > > > > Andrew
> > > > > >
> > > > > > Stephen Downard wrote:
> > > > > >
> > > > > > > Andrew,
> > > > > > > When inserting the BDE object into your project the BDE
> wizard
> > > > will
> > > > > > > execute. Select the Alias name and then modify it's parameters.
> > > You
> > > > > will
> > > > > > > want to select the PATH parameter and specify <TARGETDIR>. Once
> you
> > > > > have
> > > > > > > edited the PATH parameter make sure that you click the combo box
> > > > control
> > > > > to
> > > > > > > insert the modified item back into the combo list. Then rebuild
> > > your
> > > > > > > project. If you specify a script defined folder to represent
> the
> > > > target
> > > > > > > path you will need to use the BDE's method ScriptDefinedVar( )
> to
> > > > assign
> > > > > the
> > > > > > > target path to the variable. Please refer to the BDE help docs
> > > > located
> > > > > in
> > > > > > > the Object Gallery.
> > > > > > >
> > > > > > > Thanks,
> > > > > > > -Steve
> > > > > > >
> > > > > > > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> > > > > > > news:387DA89D.646F1750@nsw.bigpond.net.au...
> > > > > > > > Hi
> > > > > > > >
> > > > > > > > My installation requires that the BDE Alias points to a
> different
> > > > > > > > directory on the target machine than the development machine.
> At
> > > > > present
> > > > > > > > Installshield Professional 6 uses the development machine's
> Alias
> > > > > > > > configuration. How can I change the directory to the target
> > > > directory?
> > > > > > > >
> > > > > > > > Thanks
> > > > > > > >
> > > > > > > > Andrew
> > > > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> >

NewsArchive
01-18-2000, 01:00 AM
After building your project use the CAB file viewer to see if the persisted
data is getting stored in the CAB file.

"Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
news:388387D1.438C1C48@nsw.bigpond.net.au...
> Steve
>
> Thanks for your help so far. But no luck with putting the code in
OnMoving().
>
> Andrew
>
> Stephen Downard wrote:
>
> > Andrew,
> > Try implementing your code in the OnMoving() event to see if that
makes a
> > difference.
> >
> > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> > news:3882406B.5522C879@nsw.bigpond.net.au...
> > > Steve
> > >
> > > I am not able to make the program substitute the correct value. In the
BDE
> > > object the Database name is listed as <TARGETDB>. In the script I use
> > > oObj.ScriptDefinedVar("TARGETDB") = szDir. MessageBox shows that the
> > szDir is
> > > the correct value. After installation BDE administrator lists the
> > "database
> > > name" as whatever was initially set in the BDE object. Below is the
code I
> > am
> > > using:
> > >
> > > function ProgramFiles_Installing()
> > > /* Need an object variable to hold a reference to the object. */
> > > OBJECT oObj;
> > > STRING szDir;
> > > begin
> > > /* Get a reference to an BDE 5.1 object named "New BDE 5.1 Object
1".
> > */
> > > set oObj = GetObject("New BDE 5.1 1");
> > > if oObj.Status.Number != OBJ_STATUS_SUCCESS then
> > > MessageBox ( oObj.Status.Description, SEVERE );
> > > abort;
> > > endif;
> > > szDir = TARGETDIR ^ "xxx.mdb";
> > > MessageBox (szDir,INFORMATION);
> > > oObj.ScriptDefinedVar("TARGETDB") = szDir;
> > > end;
> > >
> > > Andrew
> > >
> > > Stephen Downard wrote:
> > >
> > > > To clarify:
> > > >
> > > > To assign a value to the <BDEDIR>(only if the script defined folder
is
> > not
> > > > persisted) use the following implementation:
> > > > oObj.ScriptDefinedVar("<BDEDIR>") = "your path";
> > > >
> > > > To assign a value to a <scriptdefinedfolder> that is persisted(via
the
> > BDE
> > > > Wizard) use the following implementation:
> > > > oObj.ScriptDefinedVar("scriptdefinedfolder") = "your path";
> > > > -This is because internally within the BDE object code I use the
object
> > > > TextSub.Substitue to replace the literal string that contains the
script
> > > > defined folder. So the method Substitute() should automatically
replace
> > > > this variable with the assigned value and concatenate it to the
literal
> > > > string.
> > > >
> > > > The implementation here is reverse of what you would actually
expect.
> > > > TextSub.Substitue requires the literal expression to contain the
angle
> > > > brackets and TextSub.Value is indifferent. Using TextSub.Value the
> > > > expression can contain the brackets or not; internally we remove the
> > angle
> > > > brackets anyway when using TextSub.Value. To be specific the object
> > method
> > > > ScriptDefinedVar( ) calls TextSub.Value and this is what is exposed
to
> > > > end-users. So in the BDE object end-users assign their values to
script
> > > > defined folders using this method but in the case of persisted data
I
> > use
> > > > TextSub.Substitute(only BDE Object).
> > > >
> > > > In future update always use the angle brackets. This issue is only
> > related
> > > > to the BDE Object.
> > > >
> > > > -Steve
> > > >
> > > > "Stephen Downard" <stephen@installshield.com> wrote in message
> > > > news:387f7773.0@news.installshield.com...
> > > > > Actually this is not a documentation issue the concern is with how
I
> > have
> > > > > implemented the method ScriptDefinedVar. End-users should use the
> > angle
> > > > > brackets within the parameter expression when passing into the
method
> > > > > ScriptDefinedVar. This is consistent with the implementation of
all
> > other
> > > > > objects. I use this method to perform assignments for two
different
> > > > cases.
> > > > > The first, to assign an end-user specified target location for the
> > BDEDIR
> > > > > and for script defined folders specified in the persisted data.
The
> > > > > persisted data is the data the end-user has stored via the BDE
Wizard.
> > > > > For now use the implementation that I had suggested and I will
update
> > the
> > > > > object to handle all cases.
> > > > >
> > > > > -Steve
> > > > >
> > > > >
> > > > > "Stephen Downard" <stephen@installshield.com> wrote in message
> > > > > news:387f677f.0@news.installshield.com...
> > > > > > Andrew,
> > > > > > The error in the code is located in the call to
> > ScriptDefinedVar( ).
> > > > > > Please remove the inequality signs from the parameter
expression.
> > > > > >
> > > > > > oObj.ScriptDefinedVar("TARGETDB") = szDir;
> > > > > >
> > > > > > This should solve your problem. I believe this is a
documentation
> > > > error.
> > > > > >
> > > > > > Thanks,
> > > > > > Steve
> > > > > >
> > > > > > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> > > > > > news:387E9106.58D5969A@nsw.bigpond.net.au...
> > > > > > > Steve
> > > > > > >
> > > > > > > Thanks for your help. The driver type is MSACCESS so the
parameter
> > is
> > > > > > Database
> > > > > > > Name. I tried putting <TARGETDIR>\xxx.mdb as the argument.
After
> > > > > > installation
> > > > > > > this results in the BDE parameter still being
<TARGETDIR>\xxx.mdb.
> > > > > > >
> > > > > > > So I changed the argument in the BDE parameter to <TARGETDB>
and
> > in
> > > > > > > ProgramFiles_Installing I put the following code:
> > > > > > > set oObj = GetObject("New BDE 5.1 1");
> > > > > > > MessageBox ("Getting BDE object",INFORMATION);
> > > > > > >
> > > > > > > endif;
> > > > > > > szDir = TARGETDIR ^ "xxx.mdb";
> > > > > > > oObj.ScriptDefinedVar("<TARGETDB>") = szDir;
> > > > > > >
> > > > > > > The message appears but the BDE parameter is still <TARGETDB>.
How
> > can
> > > > I
> > > > > > force
> > > > > > > the substitution?
> > > > > > >
> > > > > > > Andrew
> > > > > > >
> > > > > > > Stephen Downard wrote:
> > > > > > >
> > > > > > > > Andrew,
> > > > > > > > When inserting the BDE object into your project the BDE
> > wizard
> > > > > will
> > > > > > > > execute. Select the Alias name and then modify it's
parameters.
> > > > You
> > > > > > will
> > > > > > > > want to select the PATH parameter and specify <TARGETDIR>.
Once
> > you
> > > > > > have
> > > > > > > > edited the PATH parameter make sure that you click the combo
box
> > > > > control
> > > > > > to
> > > > > > > > insert the modified item back into the combo list. Then
rebuild
> > > > your
> > > > > > > > project. If you specify a script defined folder to
represent
> > the
> > > > > target
> > > > > > > > path you will need to use the BDE's method
criptDefinedVar( )
> > to
> > > > > assign
> > > > > > the
> > > > > > > > target path to the variable. Please refer to the BDE help
docs
> > > > > located
> > > > > > in
> > > > > > > > the Object Gallery.
> > > > > > > >
> > > > > > > > Thanks,
> > > > > > > > -Steve
> > > > > > > >
> > > > > > > > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> > > > > > > > news:387DA89D.646F1750@nsw.bigpond.net.au...
> > > > > > > > > Hi
> > > > > > > > >
> > > > > > > > > My installation requires that the BDE Alias points to a
> > different
> > > > > > > > > directory on the target machine than the development
machine.
> > At
> > > > > > present
> > > > > > > > > Installshield Professional 6 uses the development
machine's
> > Alias
> > > > > > > > > configuration. How can I change the directory to the
target
> > > > > directory?
> > > > > > > > >
> > > > > > > > > Thanks
> > > > > > > > >
> > > > > > > > > Andrew
> > > > > > > > >
> > > > > > >
> > > > > >
> > > > > >
> > > > >
> > > > >
> > >
>

NewsArchive
01-18-2000, 01:00 AM
Ok, here's a solution that works for replacing an alias path setup in the
IDE as PATH=<svDBDEST>\MyDir. Make sure that the var svDBDEST is declared as
global.

function BDE_Installing()
OBJECT oObj;
begin
// Set targets for script defined targets in BDE Object
set oObj = GetObject("BDE 5.1 1");
oObj.ScriptDefinedVar("svDBDEST") = svDBDEST;
end;

--
Steven S. Weston (sweston@westonmuir.com)
Weston & Muir (http://www.westonmuir.com)
The Banking Software Specialists
800-487-5655

NewsArchive
01-18-2000, 01:00 AM
Andrew,
Ok, I see the problem. The data is being persisted correctly, the
problem is that the code is not performing text substitution on that
particular Node Name. I will update the object code to fix this problem.

Thanks,
-Steve

"Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
news:3884DE52.530D5B57@nsw.bigpond.net.au...
> Steve
>
> I am not sure which persisted data you mean but the CAB file viewer shows:
>
> IS_Nodes(5) 1;DATABASE NAME;<TARGETDB>
>
> Andrew
>
> Stephen Downard wrote:
>
> > After building your project use the CAB file viewer to see if the
persisted
> > data is getting stored in the CAB file.
> >
> > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> > news:388387D1.438C1C48@nsw.bigpond.net.au...
> > > Steve
> > >
> > > Thanks for your help so far. But no luck with putting the code in
> > OnMoving().
> > >
> > > Andrew
> > >
> > > Stephen Downard wrote:
> > >
> > > > Andrew,
> > > > Try implementing your code in the OnMoving() event to see if that
> > makes a
> > > > difference.
> > > >
> > > > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> > > > news:3882406B.5522C879@nsw.bigpond.net.au...
> > > > > Steve
> > > > >
> > > > > I am not able to make the program substitute the correct value. In
the
> > BDE
> > > > > object the Database name is listed as <TARGETDB>. In the script I
use
> > > > > oObj.ScriptDefinedVar("TARGETDB") = szDir. MessageBox shows that
the
> > > > szDir is
> > > > > the correct value. After installation BDE administrator lists the
> > > > "database
> > > > > name" as whatever was initially set in the BDE object. Below is
the
> > code I
> > > > am
> > > > > using:
> > > > >
> > > > > function ProgramFiles_Installing()
> > > > > /* Need an object variable to hold a reference to the object.
*/
> > > > > OBJECT oObj;
> > > > > STRING szDir;
> > > > > begin
> > > > > /* Get a reference to an BDE 5.1 object named "New BDE 5.1
Object
> > 1".
> > > > */
> > > > > set oObj = GetObject("New BDE 5.1 1");
> > > > > if oObj.Status.Number != OBJ_STATUS_SUCCESS then
> > > > > MessageBox ( oObj.Status.Description, SEVERE );
> > > > > abort;
> > > > > endif;
> > > > > szDir = TARGETDIR ^ "xxx.mdb";
> > > > > MessageBox (szDir,INFORMATION);
> > > > > oObj.ScriptDefinedVar("TARGETDB") = szDir;
> > > > > end;
> > > > >
> > > > > Andrew
> > > > >
> > > > > Stephen Downard wrote:
> > > > >
> > > > > > To clarify:
> > > > > >
> > > > > > To assign a value to the <BDEDIR>(only if the script defined
folder
> > is
> > > > not
> > > > > > persisted) use the following implementation:
> > > > > > oObj.ScriptDefinedVar("<BDEDIR>") = "your path";
> > > > > >
> > > > > > To assign a value to a <scriptdefinedfolder> that is
persisted(via
> > the
> > > > BDE
> > > > > > Wizard) use the following implementation:
> > > > > > oObj.ScriptDefinedVar("scriptdefinedfolder") = "your path";
> > > > > > -This is because internally within the BDE object code I use the
> > object
> > > > > > TextSub.Substitue to replace the literal string that contains
the
> > script
> > > > > > defined folder. So the method Substitute() should automatically
> > replace
> > > > > > this variable with the assigned value and concatenate it to the
> > literal
> > > > > > string.
> > > > > >
> > > > > > The implementation here is reverse of what you would actually
> > expect.
> > > > > > TextSub.Substitue requires the literal expression to contain the
> > angle
> > > > > > brackets and TextSub.Value is indifferent. Using TextSub.Value
the
> > > > > > expression can contain the brackets or not; internally we remove
the
> > > > angle
> > > > > > brackets anyway when using TextSub.Value. To be specific the
object
> > > > method
> > > > > > ScriptDefinedVar( ) calls TextSub.Value and this is what is
exposed
> > to
> > > > > > end-users. So in the BDE object end-users assign their values
to
> > script
> > > > > > defined folders using this method but in the case of persisted
data
> > I
> > > > use
> > > > > > TextSub.Substitute(only BDE Object).
> > > > > >
> > > > > > In future update always use the angle brackets. This issue is
only
> > > > related
> > > > > > to the BDE Object.
> > > > > >
> > > > > > -Steve
> > > > > >
> > > > > > "Stephen Downard" <stephen@installshield.com> wrote in message
> > > > > > news:387f7773.0@news.installshield.com...
> > > > > > > Actually this is not a documentation issue the concern is with
how
> > I
> > > > have
> > > > > > > implemented the method ScriptDefinedVar. End-users should use
the
> > > > angle
> > > > > > > brackets within the parameter expression when passing into the
> > method
> > > > > > > ScriptDefinedVar. This is consistent with the implementation
of
> > all
> > > > other
> > > > > > > objects. I use this method to perform assignments for two
> > different
> > > > > > cases.
> > > > > > > The first, to assign an end-user specified target location for
the
> > > > BDEDIR
> > > > > > > and for script defined folders specified in the persisted
data.
> > The
> > > > > > > persisted data is the data the end-user has stored via the BDE
> > Wizard.
> > > > > > > For now use the implementation that I had suggested and I will
> > update
> > > > the
> > > > > > > object to handle all cases.
> > > > > > >
> > > > > > > -Steve
> > > > > > >
> > > > > > >
> > > > > > > "Stephen Downard" <stephen@installshield.com> wrote in message
> > > > > > > news:387f677f.0@news.installshield.com...
> > > > > > > > Andrew,
> > > > > > > > The error in the code is located in the call to
> > > > ScriptDefinedVar( ).
> > > > > > > > Please remove the inequality signs from the parameter
> > expression.
> > > > > > > >
> > > > > > > > oObj.ScriptDefinedVar("TARGETDB") = szDir;
> > > > > > > >
> > > > > > > > This should solve your problem. I believe this is a
> > documentation
> > > > > > error.
> > > > > > > >
> > > > > > > > Thanks,
> > > > > > > > Steve
> > > > > > > >
> > > > > > > > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> > > > > > > > news:387E9106.58D5969A@nsw.bigpond.net.au...
> > > > > > > > > Steve
> > > > > > > > >
> > > > > > > > > Thanks for your help. The driver type is MSACCESS so the
> > parameter
> > > > is
> > > > > > > > Database
> > > > > > > > > Name. I tried putting <TARGETDIR>\xxx.mdb as the argument.
> > After
> > > > > > > > installation
> > > > > > > > > this results in the BDE parameter still being
> > <TARGETDIR>\xxx.mdb.
> > > > > > > > >
> > > > > > > > > So I changed the argument in the BDE parameter to
<TARGETDB>
> > and
> > > > in
> > > > > > > > > ProgramFiles_Installing I put the following code:
> > > > > > > > > set oObj = GetObject("New BDE 5.1 1");
> > > > > > > > > MessageBox ("Getting BDE object",INFORMATION);
> > > > > > > > >
> > > > > > > > > endif;
> > > > > > > > > szDir = TARGETDIR ^ "xxx.mdb";
> > > > > > > > > oObj.ScriptDefinedVar("<TARGETDB>") = szDir;
> > > > > > > > >
> > > > > > > > > The message appears but the BDE parameter is still
<TARGETDB>.
> > How
> > > > can
> > > > > > I
> > > > > > > > force
> > > > > > > > > the substitution?
> > > > > > > > >
> > > > > > > > > Andrew
> > > > > > > > >
> > > > > > > > > Stephen Downard wrote:
> > > > > > > > >
> > > > > > > > > > Andrew,
> > > > > > > > > > When inserting the BDE object into your project the
BDE
> > > > wizard
> > > > > > > will
> > > > > > > > > > execute. Select the Alias name and then modify it's
> > parameters.
> > > > > > You
> > > > > > > > will
> > > > > > > > > > want to select the PATH parameter and specify
<TARGETDIR>.
> > Once
> > > > you
> > > > > > > > have
> > > > > > > > > > edited the PATH parameter make sure that you click the
combo
> > box
> > > > > > > control
> > > > > > > > to
> > > > > > > > > > insert the modified item back into the combo list. Then
> > rebuild
> > > > > > your
> > > > > > > > > > project. If you specify a script defined folder to
> > represent
> > > > the
> > > > > > > target
> > > > > > > > > > path you will need to use the BDE's method
> > criptDefinedVar( )
> > > > to
> > > > > > > assign
> > > > > > > > the
> > > > > > > > > > target path to the variable. Please refer to the BDE
help
> > docs
> > > > > > > located
> > > > > > > > in
> > > > > > > > > > the Object Gallery.
> > > > > > > > > >
> > > > > > > > > > Thanks,
> > > > > > > > > > -Steve
> > > > > > > > > >
> > > > > > > > > > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in
message
> > > > > > > > > > news:387DA89D.646F1750@nsw.bigpond.net.au...
> > > > > > > > > > > Hi
> > > > > > > > > > >
> > > > > > > > > > > My installation requires that the BDE Alias points to
a
> > > > different
> > > > > > > > > > > directory on the target machine than the development
> > machine.
> > > > At
> > > > > > > > present
> > > > > > > > > > > Installshield Professional 6 uses the development
> > machine's
> > > > Alias
> > > > > > > > > > > configuration. How can I change the directory to the
> > target
> > > > > > > directory?
> > > > > > > > > > >
> > > > > > > > > > > Thanks
> > > > > > > > > > >
> > > > > > > > > > > Andrew
> > > > > > > > > > >
> > > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > > >
> > > > >
> > >
>

NewsArchive
01-19-2000, 01:00 AM
Steve

I am not sure which persisted data you mean but the CAB file viewer shows:

IS_Nodes(5) 1;DATABASE NAME;<TARGETDB>

Andrew

Stephen Downard wrote:

> After building your project use the CAB file viewer to see if the persisted
> data is getting stored in the CAB file.
>
> "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> news:388387D1.438C1C48@nsw.bigpond.net.au...
> > Steve
> >
> > Thanks for your help so far. But no luck with putting the code in
> OnMoving().
> >
> > Andrew
> >
> > Stephen Downard wrote:
> >
> > > Andrew,
> > > Try implementing your code in the OnMoving() event to see if that
> makes a
> > > difference.
> > >
> > > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> > > news:3882406B.5522C879@nsw.bigpond.net.au...
> > > > Steve
> > > >
> > > > I am not able to make the program substitute the correct value. In the
> BDE
> > > > object the Database name is listed as <TARGETDB>. In the script I use
> > > > oObj.ScriptDefinedVar("TARGETDB") = szDir. MessageBox shows that the
> > > szDir is
> > > > the correct value. After installation BDE administrator lists the
> > > "database
> > > > name" as whatever was initially set in the BDE object. Below is the
> code I
> > > am
> > > > using:
> > > >
> > > > function ProgramFiles_Installing()
> > > > /* Need an object variable to hold a reference to the object. */
> > > > OBJECT oObj;
> > > > STRING szDir;
> > > > begin
> > > > /* Get a reference to an BDE 5.1 object named "New BDE 5.1 Object
> 1".
> > > */
> > > > set oObj = GetObject("New BDE 5.1 1");
> > > > if oObj.Status.Number != OBJ_STATUS_SUCCESS then
> > > > MessageBox ( oObj.Status.Description, SEVERE );
> > > > abort;
> > > > endif;
> > > > szDir = TARGETDIR ^ "xxx.mdb";
> > > > MessageBox (szDir,INFORMATION);
> > > > oObj.ScriptDefinedVar("TARGETDB") = szDir;
> > > > end;
> > > >
> > > > Andrew
> > > >
> > > > Stephen Downard wrote:
> > > >
> > > > > To clarify:
> > > > >
> > > > > To assign a value to the <BDEDIR>(only if the script defined folder
> is
> > > not
> > > > > persisted) use the following implementation:
> > > > > oObj.ScriptDefinedVar("<BDEDIR>") = "your path";
> > > > >
> > > > > To assign a value to a <scriptdefinedfolder> that is persisted(via
> the
> > > BDE
> > > > > Wizard) use the following implementation:
> > > > > oObj.ScriptDefinedVar("scriptdefinedfolder") = "your path";
> > > > > -This is because internally within the BDE object code I use the
> object
> > > > > TextSub.Substitue to replace the literal string that contains the
> script
> > > > > defined folder. So the method Substitute() should automatically
> replace
> > > > > this variable with the assigned value and concatenate it to the
> literal
> > > > > string.
> > > > >
> > > > > The implementation here is reverse of what you would actually
> expect.
> > > > > TextSub.Substitue requires the literal expression to contain the
> angle
> > > > > brackets and TextSub.Value is indifferent. Using TextSub.Value the
> > > > > expression can contain the brackets or not; internally we remove the
> > > angle
> > > > > brackets anyway when using TextSub.Value. To be specific the object
> > > method
> > > > > ScriptDefinedVar( ) calls TextSub.Value and this is what is exposed
> to
> > > > > end-users. So in the BDE object end-users assign their values to
> script
> > > > > defined folders using this method but in the case of persisted data
> I
> > > use
> > > > > TextSub.Substitute(only BDE Object).
> > > > >
> > > > > In future update always use the angle brackets. This issue is only
> > > related
> > > > > to the BDE Object.
> > > > >
> > > > > -Steve
> > > > >
> > > > > "Stephen Downard" <stephen@installshield.com> wrote in message
> > > > > news:387f7773.0@news.installshield.com...
> > > > > > Actually this is not a documentation issue the concern is with how
> I
> > > have
> > > > > > implemented the method ScriptDefinedVar. End-users should use the
> > > angle
> > > > > > brackets within the parameter expression when passing into the
> method
> > > > > > ScriptDefinedVar. This is consistent with the implementation of
> all
> > > other
> > > > > > objects. I use this method to perform assignments for two
> different
> > > > > cases.
> > > > > > The first, to assign an end-user specified target location for the
> > > BDEDIR
> > > > > > and for script defined folders specified in the persisted data.
> The
> > > > > > persisted data is the data the end-user has stored via the BDE
> Wizard.
> > > > > > For now use the implementation that I had suggested and I will
> update
> > > the
> > > > > > object to handle all cases.
> > > > > >
> > > > > > -Steve
> > > > > >
> > > > > >
> > > > > > "Stephen Downard" <stephen@installshield.com> wrote in message
> > > > > > news:387f677f.0@news.installshield.com...
> > > > > > > Andrew,
> > > > > > > The error in the code is located in the call to
> > > ScriptDefinedVar( ).
> > > > > > > Please remove the inequality signs from the parameter
> expression.
> > > > > > >
> > > > > > > oObj.ScriptDefinedVar("TARGETDB") = szDir;
> > > > > > >
> > > > > > > This should solve your problem. I believe this is a
> documentation
> > > > > error.
> > > > > > >
> > > > > > > Thanks,
> > > > > > > Steve
> > > > > > >
> > > > > > > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> > > > > > > news:387E9106.58D5969A@nsw.bigpond.net.au...
> > > > > > > > Steve
> > > > > > > >
> > > > > > > > Thanks for your help. The driver type is MSACCESS so the
> parameter
> > > is
> > > > > > > Database
> > > > > > > > Name. I tried putting <TARGETDIR>\xxx.mdb as the argument.
> After
> > > > > > > installation
> > > > > > > > this results in the BDE parameter still being
> <TARGETDIR>\xxx.mdb.
> > > > > > > >
> > > > > > > > So I changed the argument in the BDE parameter to <TARGETDB>
> and
> > > in
> > > > > > > > ProgramFiles_Installing I put the following code:
> > > > > > > > set oObj = GetObject("New BDE 5.1 1");
> > > > > > > > MessageBox ("Getting BDE object",INFORMATION);
> > > > > > > >
> > > > > > > > endif;
> > > > > > > > szDir = TARGETDIR ^ "xxx.mdb";
> > > > > > > > oObj.ScriptDefinedVar("<TARGETDB>") = szDir;
> > > > > > > >
> > > > > > > > The message appears but the BDE parameter is still <TARGETDB>.
> How
> > > can
> > > > > I
> > > > > > > force
> > > > > > > > the substitution?
> > > > > > > >
> > > > > > > > Andrew
> > > > > > > >
> > > > > > > > Stephen Downard wrote:
> > > > > > > >
> > > > > > > > > Andrew,
> > > > > > > > > When inserting the BDE object into your project the BDE
> > > wizard
> > > > > > will
> > > > > > > > > execute. Select the Alias name and then modify it's
> parameters.
> > > > > You
> > > > > > > will
> > > > > > > > > want to select the PATH parameter and specify <TARGETDIR>.
> Once
> > > you
> > > > > > > have
> > > > > > > > > edited the PATH parameter make sure that you click the combo
> box
> > > > > > control
> > > > > > > to
> > > > > > > > > insert the modified item back into the combo list. Then
> rebuild
> > > > > your
> > > > > > > > > project. If you specify a script defined folder to
> represent
> > > the
> > > > > > target
> > > > > > > > > path you will need to use the BDE's method
> criptDefinedVar( )
> > > to
> > > > > > assign
> > > > > > > the
> > > > > > > > > target path to the variable. Please refer to the BDE help
> docs
> > > > > > located
> > > > > > > in
> > > > > > > > > the Object Gallery.
> > > > > > > > >
> > > > > > > > > Thanks,
> > > > > > > > > -Steve
> > > > > > > > >
> > > > > > > > > "Andrew Mortlock" <atm@nsw.bigpond.net.au> wrote in message
> > > > > > > > > news:387DA89D.646F1750@nsw.bigpond.net.au...
> > > > > > > > > > Hi
> > > > > > > > > >
> > > > > > > > > > My installation requires that the BDE Alias points to a
> > > different
> > > > > > > > > > directory on the target machine than the development
> machine.
> > > At
> > > > > > > present
> > > > > > > > > > Installshield Professional 6 uses the development
> machine's
> > > Alias
> > > > > > > > > > configuration. How can I change the directory to the
> target
> > > > > > directory?
> > > > > > > > > >
> > > > > > > > > > Thanks
> > > > > > > > > >
> > > > > > > > > > Andrew
> > > > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > > >
> > > > > >
> > > > > >
> > > >
> >