{ cmn_script_ratchet = "7.2.96.5.6"; {script_completed = script_completed;} ['UNBOUND_VARIABLE: script_completed = "completed";] {return_at_end = return_at_end;} ['UNBOUND_VARIABLE: return_at_end = true;] if (EXECUTE_SCRIPT == "MODIFY_VARIABLES.CMN") { /* modify_variables.cmn */ /* install script to modify variables in an os independent way inputs : case_modify_list structured list */ { while(not(empty(case_modify_list))) { next_modification = first(case_modify_list); case_modify_list = rest(case_modify_list); modify_variable = first(next_modification); modify_value = first(rest(next_modification)); modify_ini_file = first(rest(rest(next_modification))); modify_ini_section = first(rest(rest(rest(next_modification)))); modify_location = rest(rest(rest(rest(next_modification)))); /* modify_location can be used to indicate that the variable is to be duplicated at the top level ('TOP_LEVEL) of the registry or under the usual ini section ('INI_SECTION). If you want both then both must be specified. The default if none is specified is 'INI_SECTION. This applies to NT/Win95 where there is a bug in CORE - this workaround allows the registry variable to be duplicated at the top level. Add other locations: 1) 'DES2_72_SECTION which allows variables to be set (duplicated if 'INI_SECTION is also specified) in the DES2_72 registry key. 2) 'REPADM61_SECTION which allows variables to be set (duplicated if 'INI_SECTION is also specified) in the REPADM61 registry key. 3) 'REPMAN61_SECTION which allows variables to be set (duplicated if 'INI_SECTION is also specified) in the REPMAN61 registry key. 4) 'CHELP72_SECTION which allows variables to be set (duplicated if 'INI_SECTION is also specified) in the CHELP72 registry key. 5) 'CGENC61_SECTION which allows variables to be set (duplicated if 'INI_SECTION is also specified) in the GENC20 registry key. 6) 'SYSDES61_SECTION which allows variables to be set (duplicated if 'INI_SECTION is also specified) in the SYSDES61 registry key. 7) 'DESCOM61_SECTION which allows variables to be set (duplicated if 'INI_SECTION is also specified) in the SYSDES61 registry key. */ allowable_members = list('INI_SECTION,'TOP_LEVEL,'REPIDE10_SECTION,'REPIDE10_IDE_SECTION,'REPIDE10_JVM_SECTION,'DES2_72_SECTION,'REPCOM61_SECTION,'REPADM61_CKTL_JVM_SECTION,'REPADM61_CKDM_JVM_SECTION,'REPADM61_SECTION,'REPMAN61_SECTION,'CHELP72_SECTION,'CGENC61_SECTION,'SYSDES61_SECTION, 'DESCOM61_SECTION, 'DWZ20_SECTION, 'REPADM61_DEFAULT_JVM_THIN_JDBC_SECTION); intersect(modify_location,allowable_members); if (empty(modify_location)) { add(modify_location,'INI_SECTION); } if (modify_ini_file == ora_config) { while (not(empty(modify_location))) { modify_next_location = first(modify_location); modify_location = rest(modify_location); modify_key = "HKEY_LOCAL_MACHINE"; if (modify_next_location == 'TOP_LEVEL) { /* modify_subkey = "SOFTWARE\ORACLE"; */ modify_subkey = oracle_key; } else if (modify_next_location == 'DES2_72_SECTION) { { if (user_action == 'DEINSTALL) { if (registered(des2_72_product)) { des2_72_registry = registration(des2_72_product); des2_72_ini_section = registry_filename(des2_72_registry); } else { des2_72_ini_section = "DES2_72"; } } else { des2_72_ini_section = product_filename(des2_72_product); } /* modify_subkey = "SOFTWARE\ORACLE\%des2_72_ini_section%"; */ modify_subkey = "%oracle_key%\%des2_72_ini_section%"; } ['DEFAULT(A,B,C,D): { /* information_dialog("a=%A% b=%b% c=%C% d=%D%"); */ /* modify_subkey = "SOFTWARE\ORACLE"; */ modify_subkey = oracle_key; } ] } else if (modify_next_location == 'REPADM61_SECTION) { { if (user_action == 'DEINSTALL) { if (registered(repadm61_product)) { repadm61_registry = registration(repadm61_product); repadm61_ini_section = registry_filename(repadm61_registry); } else { repadm61_ini_section = "REPADM61"; } } else { repadm61_ini_section = product_filename(repadm61_product); } /* modify_subkey = "SOFTWARE\ORACLE\%repadm61_ini_section%"; */ modify_subkey = "%oracle_key%\%repadm61_ini_section%"; } ['DEFAULT(A,B,C,D): { /* information_dialog("a=%A% b=%b% c=%C% d=%D%"); */ /* modify_subkey = "SOFTWARE\ORACLE"; */ modify_subkey = oracle_key; } ] } else if (modify_next_location == 'REPCOM61_SECTION) { { if (user_action == 'DEINSTALL) { if (registered(repcom61_product)) { repcom61_registry = registration(repcom61_product); repcom61_ini_section = registry_filename(repcom61_registry); } else { repcom61_ini_section = "REPCOM61"; } } else { repcom61_ini_section = product_filename(repcom61_product); } /* modify_subkey = "SOFTWARE\ORACLE\%repcom61_ini_section%"; */ modify_subkey = "%oracle_key%\%repcom61_ini_section%"; } ['DEFAULT(A,B,C,D): { /* information_dialog("a=%A% b=%b% c=%C% d=%D%"); */ /* modify_subkey = "SOFTWARE\ORACLE"; */ modify_subkey = oracle_key; } ] } else if (modify_next_location == 'REPADM61_CKTL_JVM_SECTION) { { if (user_action == 'DEINSTALL) { if (registered(repadm61_product)) { repadm61_registry = registration(repadm61_product); repadm61_ini_section = registry_filename(repadm61_registry); } else { repadm61_ini_section = "REPADM61"; } } else { repadm61_ini_section = product_filename(repadm61_product); } /* modify_subkey = "SOFTWARE\ORACLE\%repadm61_ini_section%"; */ modify_subkey = "%oracle_key%\%repadm61_ini_section%\CKTL_JVM_PARAMS"; } ['DEFAULT(A,B,C,D): { /* information_dialog("a=%A% b=%b% c=%C% d=%D%"); */ /* modify_subkey = "SOFTWARE\ORACLE\%repadm61_ini_section%"; */ modify_subkey = "%oracle_key%\%repadm61_ini_section%\CKTL_JVM_PARAMS"; } ] } else if (modify_next_location == 'REPADM61_CKDM_JVM_SECTION) { { if (user_action == 'DEINSTALL) { if (registered(repadm61_product)) { repadm61_registry = registration(repadm61_product); repadm61_ini_section = registry_filename(repadm61_registry); } else { repadm61_ini_section = "REPADM61"; } } else { repadm61_ini_section = product_filename(repadm61_product); } /* modify_subkey = "SOFTWARE\ORACLE\%repadm61_ini_section%"; */ modify_subkey = "%oracle_key%\%repadm61_ini_section%\CKDM_JVM_PARAMS"; } ['DEFAULT(A,B,C,D): { /* information_dialog("a=%A% b=%b% c=%C% d=%D%"); */ /* modify_subkey = "SOFTWARE\ORACLE\%repadm61_ini_section%"; */ modify_subkey = "%oracle_key%\%repadm61_ini_section%\CKDM_JVM_PARAMS"; } ] } else if (modify_next_location == 'REPADM61_DEFAULT_JVM_THIN_JDBC_SECTION) { { if (user_action == 'DEINSTALL) { if (registered(repadm61_product)) { repadm61_registry = registration(repadm61_product); repadm61_ini_section = registry_filename(repadm61_registry); } else { repadm61_ini_section = "REPADM61"; } } else { repadm61_ini_section = product_filename(repadm61_product); } /* modify_subkey = "SOFTWARE\ORACLE\%repadm61_ini_section%"; */ modify_subkey = "%oracle_key%\%repadm61_ini_section%\DEFAULT_JVM_PARAMS_THIN_JDBC"; } ['DEFAULT(A,B,C,D): { /* information_dialog("a=%A% b=%b% c=%C% d=%D%"); */ /* modify_subkey = "SOFTWARE\ORACLE\%repadm61_ini_section%"; */ modify_subkey = "%oracle_key%\%repadm61_ini_section%\DEFAULT_JVM_PARAMS_THIN_JDBC"; } ] } else if (modify_next_location == 'REPIDE10_SECTION) { { if (user_action == 'DEINSTALL) { if (registered(repide10_product)) { repide10_registry = registration(repide10_product); repide10_ini_section = registry_filename(repide10_registry); } else { repide10_ini_section = "REPIDE10"; } } else { repide10_ini_section = product_filename(repide10_product); } /* modify_subkey = "SOFTWARE\ORACLE\%repide10_ini_section%"; */ modify_subkey = "%oracle_key%\%repide10_ini_section%"; } ['DEFAULT(A,B,C,D): { /* information_dialog("a=%A% b=%b% c=%C% d=%D%"); */ /* modify_subkey = "SOFTWARE\ORACLE"; */ modify_subkey = oracle_key; } ] } else if (modify_next_location == 'REPIDE10_IDE_SECTION) { { if (user_action == 'DEINSTALL) { if (registered(repide10_product)) { repide10_registry = registration(repide10_product); repide10_ini_section = registry_filename(repide10_registry); } else { repide10_ini_section = "REPIDE10"; } } else { repide10_ini_section = product_filename(repide10_product); } /* modify_subkey = "SOFTWARE\ORACLE\%repide10_ini_section%"; */ modify_subkey = "%oracle_key%\%repide10_ini_section%"; } ['DEFAULT(A,B,C,D): { /* information_dialog("a=%A% b=%b% c=%C% d=%D%"); */ /* modify_subkey = "SOFTWARE\ORACLE"; */ modify_subkey = oracle_key; } ] } else if (modify_next_location == 'REPIDE10_JVM_SECTION) { { if (user_action == 'DEINSTALL) { if (registered(repide10_product)) { repide10_registry = registration(repide10_product); repide10_ini_section = registry_filename(repide10_registry); } else { repide10_ini_section = "REPIDE10"; } } else { repide10_ini_section = product_filename(repide10_product); } /* modify_subkey = "SOFTWARE\ORACLE\%repide10_ini_section%"; */ modify_subkey = "%oracle_key%\%repide10_ini_section%"; } ['DEFAULT(A,B,C,D): { /* information_dialog("a=%A% b=%b% c=%C% d=%D%"); */ /* modify_subkey = "SOFTWARE\ORACLE"; */ modify_subkey = oracle_key; } ] } else if (modify_next_location == 'REPMAN61_SECTION) { { if (user_action == 'DEINSTALL) { if (registered(repman61_product)) { repman61_registry = registration(repman61_product); repman61_ini_section = registry_filename(repman61_registry); } else { repman61_ini_section = "REPMAN61"; } } else { repman61_ini_section = product_filename(repman61_product); } /* modify_subkey = "SOFTWARE\ORACLE\%repman61_ini_section%"; */ modify_subkey = "%oracle_key%\%repman61_ini_section%"; } ['DEFAULT(A,B,C,D): { /* information_dialog("a=%A% b=%b% c=%C% d=%D%"); */ /* modify_subkey = "SOFTWARE\ORACLE"; */ modify_subkey = oracle_key; } ] } else if (modify_next_location == 'CHELP72_SECTION) { { if (user_action == 'DEINSTALL) { if (registered(chelp72_product)) { chelp72_registry = registration(chelp72_product); chelp72_ini_section = registry_filename(chelp72_registry); } else { chelp72_ini_section = "CHELP72"; } } else { chelp72_ini_section = product_filename(chelp72_product); } /* modify_subkey = "SOFTWARE\ORACLE\%chelp72_ini_section%"; */ modify_subkey = "%oracle_key%\%chelp72_ini_section%"; } ['DEFAULT(A,B,C,D): { /* information_dialog("a=%A% b=%b% c=%C% d=%D%"); */ /* modify_subkey = "SOFTWARE\ORACLE"; */ modify_subkey = oracle_key; } ] } else if (modify_next_location == 'CGENC61_SECTION) { { if (user_action == 'DEINSTALL) { if (registered(cgenc61_product)) { cgenc61_registry = registration(cgenc61_product); cgenc61_ini_section = registry_filename(cgenc61_registry); } else { cgenc61_ini_section = "CGENC61"; } } else { cgenc61_ini_section = product_filename(cgenc61_product); } /* modify_subkey = "SOFTWARE\ORACLE\%cgenc61_ini_section%"; */ modify_subkey = "%oracle_key%\%cgenc61_ini_section%"; } ['DEFAULT(A,B,C,D): { /* information_dialog("a=%A% b=%b% c=%C% d=%D%"); */ /* modify_subkey = "SOFTWARE\ORACLE"; */ modify_subkey = oracle_key; } ] } else if (modify_next_location == 'SYSDES61_SECTION) { { if (user_action == 'DEINSTALL) { if (registered(sysdes61_product)) { sysdes61_registry = registration(sysdes61_product); sysdes61_ini_section = registry_filename(sysdes61_registry); } else { sysdes61_ini_section = "SYSDES61"; } } else { sysdes61_ini_section = product_filename(sysdes61_product); } /* modify_subkey = "SOFTWARE\ORACLE\%sysdes61_ini_section%"; */ modify_subkey = "%oracle_key%\%sysdes61_ini_section%"; } ['DEFAULT(A,B,C,D): { /* information_dialog("a=%A% b=%b% c=%C% d=%D%"); */ /* modify_subkey = "SOFTWARE\ORACLE"; */ modify_subkey = oracle_key; } ] } else if (modify_next_location == 'DESCOM61_SECTION) { { if (user_action == 'DEINSTALL) { if (registered(descom61_product)) { descom61_registry = registration(descom61_product); descom61_ini_section = registry_filename(descom61_registry); } else { descom61_ini_section = "DESCOM61"; } } else { descom61_ini_section = product_filename(descom61_product); } /* modify_subkey = "SOFTWARE\ORACLE\%descom61_ini_section%"; */ modify_subkey = "%oracle_key%\%descom61_ini_section%"; } ['DEFAULT(A,B,C,D): { /* information_dialog("a=%A% b=%b% c=%C% d=%D%"); */ /* modify_subkey = "SOFTWARE\ORACLE"; */ modify_subkey = oracle_key; } ] } else if (modify_next_location == 'DWZ20_SECTION) { dwz20_ini_section = "DWZ20"; /* modify_subkey = "SOFTWARE\ORACLE\%dwz20_ini_section%"; */ modify_subkey = "%oracle_key%\%dwz20_ini_section%"; } else { /* modify_subkey = "SOFTWARE\ORACLE\%modify_ini_section%"; */ modify_subkey = "%oracle_key%\%modify_ini_section%"; } /* if modify_variable is null the we want to delete the entire key */ if (not(modify_variable == "")) { /* if modify_value is null the we want to delete the association */ if (not(modify_value == "")) { /* modify_value is valid so make sure key exists */ win32_create_key(modify_key, modify_subkey); /* special cases */ if (modify_next_location == 'REPIDE10_IDE_SECTION) { /* modify_subkey = "SOFTWARE\ORACLE\%repide10_ini_section%\IDE_PROPERTIES"; */ modify_subkey = "%oracle_key%\%repide10_ini_section%\IDE_PROPERTIES"; win32_create_key(modify_key, modify_subkey); /* modify_subkey = "SOFTWARE\ORACLE\%repide10_ini_section%\IDE_PROPERTIES\Java_Global"; */ modify_subkey = "%oracle_key%\%repide10_ini_section%\IDE_PROPERTIES\Java_Global"; win32_create_key(modify_key, modify_subkey); } if (modify_next_location == 'REPIDE10_JVM_SECTION) { /* modify_subkey = "SOFTWARE\ORACLE\%repide10_ini_section%\JVM_PROPERTIES"; */ modify_subkey = "%oracle_key%\%repide10_ini_section%\JVM_PROPERTIES"; win32_create_key(modify_key, modify_subkey); } if (modify_next_location == 'REPADM61_CKTL_JVM_SECTION) { /* modify_subkey = "SOFTWARE\ORACLE\%repadm61_ini_section%\CKTL_JVM_PARAMS"; */ modify_subkey = "%oracle_key%\%repadm61_ini_section%\CKTL_JVM_PARAMS"; win32_create_key(modify_key, modify_subkey); } if (modify_next_location == 'REPADM61_CKDM_JVM_SECTION) { /* modify_subkey = "SOFTWARE\ORACLE\%repadm61_ini_section%\CKDM_JVM_PARAMS"; */ modify_subkey = "%oracle_key%\%repadm61_ini_section%\CKDM_JVM_PARAMS"; win32_create_key(modify_key, modify_subkey); } if (modify_next_location == 'REPADM61_DEFAULT_JVM_THIN_JDBC_SECTION) { /* modify_subkey = "SOFTWARE\ORACLE\%repadm61_ini_section%\DEFAULT_JVM_PARAMS_THIN_JDBC"; */ modify_subkey = "%oracle_key%\%repadm61_ini_section%\DEFAULT_JVM_PARAMS_THIN_JDBC"; win32_create_key(modify_key, modify_subkey); } } { win32_set_value(modify_key, modify_subkey, modify_variable, modify_value); if (not(modify_next_location == 'INI_SECTION)) { /* when the product is registered/referenced the des2k_72.ins script registers the entire subkey. These values are outside the default sub-key so register them explicitly. */ /* 32 bit OCSM */ if (not(modify_value == "")) { if (not(user_action == 'deinstall)) { win32_register_key(modify_key,modify_subkey,modify_variable); } } } } ['FILE_NOT_FOUND(A,B,C,D): { if (not(modify_value == "")) { skip = yesno_dialog("%B%%carriage_return%%carriage_return%Skip error and continue?"); if (not(skip)) signal(A,B); } } ] } else { /* delete the key */ { modify_subkey = "%modify_subkey%\%modify_variable%"; win32_delete_key(modify_key, modify_subkey); } ['FILE_NOT_FOUND(A,B,C,D): continue(); 'PERMISSION_DENIED: continue(); ] } } } else { /* if modify_variable is null the we want to delete the entire section - not possible at moment */ if (not(modify_variable == "")) { /* modify_variable is valid */ information_dialog("can not modify registry entry for %modify_ini_file% under %operating_system%, using ini file instead"); modify(modify_variable, modify_value, modify_ini_file, modify_ini_section); } } } EXECUTE_SCRIPT = script_completed; script_return_value = 0; if (return_at_end) return(script_return_value); } } if (EXECUTE_SCRIPT == "TRANSLATE_VARIABLES.CMN") { /* translate_variables.cmn */ /* install script to translate variables in an os independent way inputs : case_translate_list structured list */ { /* while(not(empty(case_translate_list))) */ { /* next_translation = first(case_translate_list); */ next_translation = case_translate_list; /* case_translate_list = rest(case_translate_list); */ translate_variable = first(next_translation); translate_ini_file = first(rest(next_translation)); translate_ini_section = first(rest(rest(next_translation))); translate_location = rest(rest(rest(next_translation))); /* translate_location can be used to indicate that the variable is to be translated from the top level ('TOP_LEVEL) of the registry instead of the usual ini section ('INI_SECTION). The default if 'TOP_LEVEL is not specified is 'INI_SECTION. This only applies to NT/Win95 where there is a bug in CORE - this is the workaround. The other permitted value is 'SYSTEM which indicates a system variable. */ if (translate_ini_file == ora_config) { translate_key = "HKEY_LOCAL_MACHINE"; if (member(translate_location ,'SYSTEM)) { translate_subkey = "SOFTWARE"; } else if (member(translate_location ,'TOP_LEVEL)) { /* translate_subkey = "SOFTWARE\ORACLE"; */ translate_subkey = oracle_key; } else { /* translate_subkey = "SOFTWARE\ORACLE\%translate_ini_section%"; */ translate_subkey = "%oracle_key%\%translate_ini_section%"; } /* information_dialog("variable = %translate_variable% subkey = %translate_subkey%"); */ { if (member(translate_location ,'SYSTEM)) { /* let the installer work out where to get this from */ translate_value = v7_translate(translate_variable); } else if (member(translate_location ,'TOP_LEVEL)) { /* there is a new translate() variant which is MOH compliant (but does not know about sub_keys) Use this all the time instead of: v7_translate() which is not MOH compliant */ translate_value = translate(translate_variable,ora_config); } else if (member(translate_location ,'TOP_LEVEL) && (operating_system == "nt")) { /* there is a bug in the NT installer when using nt/win32_get_value to get long values. If the variable is at the top level then we can use the buggy v7_translate from CORE */ translate_value = v7_translate(translate_variable); } else { translate_value = win32_get_value(translate_key, translate_subkey, translate_variable); } } ['FILE_NOT_FOUND(A,B,C,D): { /* signal an unbound enviroīment variable which should be caught by the calling program, but give the original error message so that problems can be traced. */ signal('UNBOUND_ENVIRONMENT_VARIABLE,B); } ] } else { information_dialog("can not translate registry entry for %translate_ini_file% under %operating_system%, using ini file instead"); translate_value = translate(translate_variable, translate_ini_file, translate_ini_section); } } EXECUTE_SCRIPT = script_completed; script_return_value = translate_value; if (return_at_end) return(script_return_value); } } if (EXECUTE_SCRIPT == "DES2_BB.DIS") { /* des2_bb.dis */ /* displays the billboard (graphics bmp file) */ /* inputs: case_graphics_file : string (filename) */ { { if (debug_values) information_dialog("trying to display %case_graphics_file%"); if (case_graphics_file != "") { /* there are a number of places we can look for the file - make a list */ graphics_file_list = list(); /* look for a local cached copy */ graphics_file = instantiate("%installer_home%\%case_graphics_file%"); add(graphics_file_list,graphics_file); /* look for a language translation with bundle */ { if (not(CASE_GRAPHICS_DIRECTORY == "")) { this_prod_loc = product_location(desnls72_product); graphics_file = instantiate("%product_home%\%this_prod_loc%\%nls_abbreviation%\%CASE_GRAPHICS_DIRECTORY%\%case_graphics_file%"); add(graphics_file_list,graphics_file); } } ['UNBOUND_VARIABLE: continue();] /* look for a language translation */ { this_prod_loc = product_location(desnls72_product); graphics_file = instantiate("%product_home%\%this_prod_loc%\%nls_abbreviation%\%case_graphics_file%"); add(graphics_file_list,graphics_file); } ['UNBOUND_VARIABLE: continue();] /* look for a (default) US language translation with bundle */ { if (not(CASE_GRAPHICS_DIRECTORY == "")) { this_prod_loc = product_location(desnls72_product); graphics_file = instantiate("%product_home%\%this_prod_loc%\us\%CASE_GRAPHICS_DIRECTORY%\%case_graphics_file%"); add(graphics_file_list,graphics_file); } } ['UNBOUND_VARIABLE: continue();] /* look for a (default) US language translation */ { this_prod_loc = product_location(des2l70_product); graphics_file = instantiate("%product_home%\%this_prod_loc%\us\%case_graphics_file%"); add(graphics_file_list,graphics_file); } ['UNBOUND_VARIABLE: continue();] /* look in the products own directory on the install medium */ { this_prod_loc = product_location(current_product); graphics_file = instantiate("%product_home%\%this_prod_loc%\%case_graphics_file%"); add(graphics_file_list,graphics_file); } ['UNBOUND_VARIABLE: continue();] /* look in the header products own directory in the install medium */ { header_prod_loc = product_location(header_product); graphics_file = instantiate("%product_home%\%header_prod_loc%\%case_graphics_file%"); add(graphics_file_list,graphics_file); } ['UNBOUND_VARIABLE: continue();] while (not(empty(graphics_file_list))) { graphics_file = first(graphics_file_list); graphics_file_list = rest(graphics_file_list); if (debug_values) information_dialog("looking for file %graphics_file%"); if (exists(graphics_file)) { if (debug_values) information_dialog("displaying %graphics_file%"); ui_graphics(graphics_file); add(case_billboards_displayed,case_graphics_file); break(); } } } } /* ['default: continue();] */ EXECUTE_SCRIPT = script_completed; script_return_value = 0; if (return_at_end) return(script_return_value); } } if (EXECUTE_SCRIPT == "DES2_BB.REM") { /* des2_bb.rem */ /* removes the billboard (graphics bmp file) */ /* inputs: case_graphics_file : string (filename) */ { { if (debug_values) information_dialog("trying to remove %case_graphics_file%"); /* remove the entry from the end. Note that neither subtract nor extract can do this */ /* subtract(case_billboards_displayed,list(case_graphics_file)); */ /* extract(case_billboards_displayed,case_graphics_file); */ temp_list = reverse(case_billboards_displayed,'NOMUTATE); temp_list = rest(temp_list); temp_list = reverse(temp_list,'NOMUTATE); /* clear the list by mutating it */ intersect(case_billboards_displayed,list()); /* add the entries back in in the correct order */ while (not(empty(temp_list))) { next_temp = first(temp_list); temp_list = rest(temp_list); add(case_billboards_displayed,next_temp); } if (empty(case_billboards_displayed)) { if (debug_values) information_dialog("removing %case_graphics_file%"); ui_graphics(); } } ['default: continue();] EXECUTE_SCRIPT = script_completed; script_return_value = 0; if (return_at_end) return(script_return_value); } } if (EXECUTE_SCRIPT == "FILASSOC.VRF") { /* filassoc.vrf */ /* return the file asscoiated with the given extension */ /* inputs: case_file_extension : string outputs: returns: assoc_filespec : string */ { debug_filassoc = false; { case_file_extension = first(case_file_assoc); case_file_command = first(rest(case_file_assoc)); if (case_file_extension == "") signal('UNBOUND_VARIABLE); application_name = win32_get_value("HKEY_LOCAL_MACHINE","SOFTWARE\Classes\%case_file_extension%",""); /* check to see if the last thing we did was inspect these registry entries */ ini_section = product_filename(current_product); modify_key = "HKEY_LOCAL_MACHINE"; /* modify_subkey = "SOFTWARE\ORACLE\%ini_section%"; */ modify_subkey = "%oracle_key%\%ini_section%"; { if (debug_filassoc) information_dialog("checking %modify_subkey%\ANALYZE_FILASSOC_EXTENSION"); modify_variable = "ANALYZE_FILASSOC_EXTENSION"; analyze_filassoc_extension = win32_get_value(modify_key, modify_subkey, modify_variable); if (debug_filassoc) information_dialog("checking %modify_subkey%\ANALYZE_FILASSOC_APPLICATION"); modify_variable = "ANALYZE_FILASSOC_APPLICATION"; analyze_filassoc_application = win32_get_value(modify_key, modify_subkey, modify_variable); if (debug_filassoc) information_dialog("checking %modify_subkey%\ANALYZE_FILASSOC_COMMAND"); modify_variable = "ANALYZE_FILASSOC_COMMAND"; analyze_filassoc_command = win32_get_value(modify_key, modify_subkey, modify_variable); if (debug_filassoc) information_dialog("end checking %modify_subkey%\ANALYZE_FILASSOC_COMMAND"); } ['UNBOUND_VARIABLE, 'INVALID_KEY, 'FILE_NOT_FOUND, 'OS_ERROR : analyze_filassoc_extension = "";] if (analyze_filassoc_extension != "") { /* yes it was - so it probably crashed. Put up an error message */ /* remove the registry log in case the user cancels the message to correct the error and start again */ if (debug_filassoc) information_dialog("removing what we did - prior to error message"); { modify_variable = "ANALYZE_FILASSOC_EXTENSION"; modify_value = ""; win32_set_value(modify_key, modify_subkey, modify_variable, modify_value); } ['UNBOUND_VARIABLE, 'INVALID_KEY, 'FILE_NOT_FOUND, 'OS_ERROR: continue(); ] { modify_variable = "ANALYZE_FILASSOC_APPLICATION"; modify_value = ""; win32_set_value(modify_key, modify_subkey, modify_variable, modify_value); } ['UNBOUND_VARIABLE, 'INVALID_KEY, 'FILE_NOT_FOUND, 'OS_ERROR: continue(); ] { modify_variable = "ANALYZE_FILASSOC_COMMAND"; modify_value = ""; win32_set_value(modify_key, modify_subkey, modify_variable, modify_value); } ['UNBOUND_VARIABLE, 'INVALID_KEY, 'FILE_NOT_FOUND, 'OS_ERROR: continue(); ] if (debug_filassoc) information_dialog("end removing what we did - prior to error message"); information_dialog(instantiate(analyze_filassoc_error),instantiate(analyze_filassoc_content),instantiate(analyze_filassoc_help)); assoc_filespec = "NOTEPAD %%1"; /* signal('UNBOUND_VARIABLE); */ } else { /* record what we are about to do - in case it crashes */ if (debug_filassoc) information_dialog("recorded what we are about to do"); modify_variable = "ANALYZE_FILASSOC_EXTENSION"; modify_value = case_file_extension; win32_set_value(modify_key, modify_subkey, modify_variable, modify_value); modify_variable = "ANALYZE_FILASSOC_APPLICATION"; modify_value = application_name; win32_set_value(modify_key, modify_subkey, modify_variable, modify_value); modify_variable = "ANALYZE_FILASSOC_COMMAND"; modify_value = case_file_command; win32_set_value(modify_key, modify_subkey, modify_variable, modify_value); if (debug_filassoc) information_dialog("recorded what we are about to do"); assoc_filespec = win32_get_value("HKEY_LOCAL_MACHINE","SOFTWARE\Classes\%application_name%\shell\%case_file_command%\command",""); if (debug_filassoc) information_dialog("end recorded what we are about to do"); } } ['UNBOUND_VARIABLE, 'INVALID_KEY, 'FILE_NOT_FOUND, 'OS_ERROR: assoc_filespec = ""; ] /* either it succeeed or we put up an error message. Since it didn't crash, remove the entries that said what we were doing. */ if (debug_filassoc) information_dialog("removing what we did"); { modify_variable = "ANALYZE_FILASSOC_EXTENSION"; modify_value = ""; win32_set_value(modify_key, modify_subkey, modify_variable, modify_value); } ['UNBOUND_VARIABLE, 'INVALID_KEY, 'FILE_NOT_FOUND, 'OS_ERROR: continue(); ] { modify_variable = "ANALYZE_FILASSOC_APPLICATION"; modify_value = ""; win32_set_value(modify_key, modify_subkey, modify_variable, modify_value); } ['UNBOUND_VARIABLE, 'INVALID_KEY, 'FILE_NOT_FOUND, 'OS_ERROR: continue(); ] { modify_variable = "ANALYZE_FILASSOC_COMMAND"; modify_value = ""; win32_set_value(modify_key, modify_subkey, modify_variable, modify_value); } ['UNBOUND_VARIABLE, 'INVALID_KEY, 'FILE_NOT_FOUND, 'OS_ERROR: continue(); ] if (debug_filassoc) information_dialog("end removing what we did. Returning %assoc_filespec%"); script_return_value = assoc_filespec; EXECUTE_SCRIPT = script_completed; if (return_at_end) return(script_return_value); } } }