File Associations
Posted 25 July 2001 - 18:02
Posted 26 July 2001 - 22:04
Pop up a yes/no box. Set the property based on their answer. Then set the "file association" function (see example below) to run based on the property just set.
ex:
function SetZZZ (hMSI)
NUMBER nZzzResult;
begin
// Set .zzz to be a text file.
RegDBSetDefaultRoot(HKEY_CLASSES_ROOT);
RegDBCreateKeyEx(".zzz","");
nZzzResult = RegDBSetKeyValueEx(".zzz","",REGDB_STRING,"txtfile",-1);
if nZzzResult <0 then
MessageBox ("Did not set .zzz files correctly", INFORMATION);
endif;
end;
(Edited by Kate at 10:04 pm on July 26, 2001)
Posted 26 July 2001 - 23:42
I made an InstallScript and then created a Custom Action to run the script, but when I try and build the release I get the following error:
** Error -1024: File P:\MaxSim\MaxSim\Setup\Product Configuration 1\Interm\Setup.inx not found. Cannot stream the file into the Binary table
Any ideas how to fix this error? My scipt compiled without any errors or warnings so I don't think it is that. Thanks again for all your help.
Posted 27 July 2001 - 17:31
I fixed the error, but I don't think the script is working properly. Here is what I need to accomplish.
There are three file extensions that the software that is going to be installed is going to be using. There are two different programs that are being installed. One is going to use .mxc and the other program uses .mxs and .mxr. The script compiles fine, but when I checked to see if it associated the file types in windows by going to My Computer->View->Options->File Types, they aren't displayed there. Do you have any idea of how to get it to appear there?