Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

Problem with installation to TargetDisk


4 replies to this topic

el puGo!

el puGo!
  • Members
  • 16 posts

Posted 15 July 2004 - 12:18

I have here an installation that makes me problems (I use InstallShield DevStudio 9).
However, in this installation there is a component this one should not be installed into the target directory but on the target drive. For example if the user chooses D:\programs\any_name\... for the installation the component should be copied directly under D:\.
But although I use TARGETDISK as target directory for this component it is always copied on drive C:\ in this example.
Can somebody help me?

Ozone

Ozone
  • Full Members
  • 77 posts

Posted 15 July 2004 - 14:13

cool.gif TARGETDISK will return the disk drive that contains Win.ini, and that is usually the C: drive.

You need to return the disk drive of the TARGETDIR. Use the function GetDisk(szPath, svDisk). The user can also use a UNC path. If a UNC path is used, GetDisk return the server name and the shared device name in the format \\server\sharedevice. If a drive designation is not included, the function will fail.

Return values

0 = success
< 0 = failed to return disk


ret = GetDisk ( TARGETDIR, svDisk)


Ozone

Ozone
  • Full Members
  • 77 posts

Posted 15 July 2004 - 14:53

I think I only gave you half of the answer. blink.gif I gave you the script method of obtaining the disk drive, but I need to get you the part that needs to be added in the IDE.
Go to Project Assistant. Then click on the Application Files on the lower part on the tab. Add a new folder name to the Script Defined Folders. I named mine <ROOT> for this example.

Now in the Installation Designer, set the Destination property to the <ROOT> folder.

Make sure that in your script, you use the GetDisk(szPath, svDisk) function to define the varable ROOT before you move the data. Do this right after the user interface that selects the destination path.

ret = GetDisk( TARGETDIR, ROOT)

el puGo!

el puGo!
  • Members
  • 16 posts

Posted 16 July 2004 - 09:39

thx for your fast answer...
I will give you a feedback if it works

el puGo!

el puGo!
  • Members
  • 16 posts

Posted 26 July 2004 - 09:45

it seems to work...