I need to change the [INSTALLDIR] based on the feature selected from the AskOptions dialog box. But FeatureIsItemSelected method is NOT working for me. Even though i select a particular feature from the AskOptions dialog, it always returns an error -105 (which is Specified feature cannot be found in the media). The below code snippet is how i tried to use the FeatureIsItemSelected method. Can you please tell me what mistake i am doing.
nResult = SdAskOptions ("Product Selection", "Select the product to install.",
"", "", "DefaultFeature",
EXCLUSIVE);
if (nResult = BACK) goto Dlg_SdCustomerInformation;
szInstallDirPath = "";
szInstallDirPath = INSTALLDIR;
nRes = FeatureIsItemSelected(MEDIA, "Prod1");
if nRes = 1 then
szInstallDirPath = szInstallDirPath^"Prod1";
else
szInstallDirPath = szInstallDirPath^"Prod2";
endif;
FeatureSetTarget(MEDIA, "<INSTALLDIR>", szInstallDirPath);
I also tried to use "FeatureGetData", but it also returns false everytime. Any help would be greatly appritiated.
thanks & regards,
Jayag
Edited by Jayag, 27 March 2006 - 00:59.