This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- Re: XCopyFiles function and add cost to feature
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 14, 2008
11:12 AM
XCopyFiles function and add cost to feature
Hi, I need to use XCopyFiles and I wish I could add cost of files and/or directories that I have to copy to a feature at runtime.
Could I do this?
thank u,
Davide
Could I do this?
thank u,
Davide
(3) Replies
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 14, 2008
01:04 PM
Check out Installscript functions like FeatureAddCost to achieve this.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 14, 2008
04:17 PM
I tried with the following code but it still doesnt work. It show me the same cost of the feature..where I m wronging? Thanks
Davide
function OnBegin()
STRING svResulta;
NUMBER nvResulta,nvResulta1, nvCostLow, nvCostHigh;
begin
GetFileInfo (SRCDIR ^ "CIAO" ^ "net.pdf",FILE_SIZE_LOW,nvResulta,svResulta);
NumToStr (svResulta, nvResulta);
MessageBox ( svResulta , WARNING );
GetFileInfo (SRCDIR ^ "CIAO" ^ "net.pdf",FILE_SIZE_HIGH,nvResulta1,svResulta);
NumToStr (svResulta, nvResulta1);
MessageBox ( svResulta , WARNING );
CalculateAndAddFileCost( nvResulta, nvResulta1, SRCDIR ^ "CIAO" ^ "net.pdf", 0, nvCostHigh, nvCostLow );
FeatureAddCost ( MEDIA, "Minima", SRCDIR ^ "CIAO" ^ "net.pdf", nvResulta,nvResulta1);
FeatureAddCost ( MEDIA, "Minima", TARGETDIR, nvResulta,nvResulta1);
end;
Davide
function OnBegin()
STRING svResulta;
NUMBER nvResulta,nvResulta1, nvCostLow, nvCostHigh;
begin
GetFileInfo (SRCDIR ^ "CIAO" ^ "net.pdf",FILE_SIZE_LOW,nvResulta,svResulta);
NumToStr (svResulta, nvResulta);
MessageBox ( svResulta , WARNING );
GetFileInfo (SRCDIR ^ "CIAO" ^ "net.pdf",FILE_SIZE_HIGH,nvResulta1,svResulta);
NumToStr (svResulta, nvResulta1);
MessageBox ( svResulta , WARNING );
CalculateAndAddFileCost( nvResulta, nvResulta1, SRCDIR ^ "CIAO" ^ "net.pdf", 0, nvCostHigh, nvCostLow );
FeatureAddCost ( MEDIA, "Minima", SRCDIR ^ "CIAO" ^ "net.pdf", nvResulta,nvResulta1);
FeatureAddCost ( MEDIA, "Minima", TARGETDIR, nvResulta,nvResulta1);
end;
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 15, 2008
09:47 AM
Can someone help me????....I'm so in a hurry!!!
Thank u in advance,
Davide
Thank u in advance,
Davide