/* Copyright (c) Oracle Corporation 1994. All Rights Reserved */ /************************************************************************* NAME user1.avf - user-defined .avf script DESCRIPTION This script allows users access to their own customizable .avf script. OWNER 10/08/1999 TJOSE This is requried becuase once we add nt function **************************************************************************/ { /* Following segment is requried to stop the service if it is running */ ifsrv60_exe = "%ORACLE_HOME%\bin\ifsrv60.exe"; rwmts60_exe = "%ORACLE_HOME%\bin\rwmts60.exe"; temp_exe = "%ORACLE_HOME%\bin\temp_exe_dest.exe"; ifsrv60_has_to_restart = FALSE; ifsrv60_running = FALSE; rwmts60_has_to_restart = FALSE; rwmts60_running = FALSE; service_running = TRUE; forms_server_running_msg = nls("forms_server_running_msg","File %ORACLE_HOME%\bin\ifsrv60.exe is in use. Please stop the Forms Server service first and Click OK to continue"); reports_server_running_msg = nls("reports_server_running_msg","File %ORACLE_HOME%\bin\rwmts60.exe is in use. Please stop the Reports Server service first and Click OK to continue"); if(exists(ifsrv60_exe)) { while(service_running) { {copy_file(ifsrv60_exe,temp_exe); move_file(temp_exe,ifsrv60_exe); ifsrv60_running = FALSE; service_running = FALSE;} ['PERMISSION_DENIED, 'OS_ERROR: ifsrv60_running = TRUE;] if(ifsrv60_running) { if((earlier_version(w32frunw60,"6.0.6.0.0"))||not(registered("w32frunw60"))) { information_dialog(forms_server_running_msg); } else { {winnt_stop_service("OracleFormsServer-Forms60Server%oracle_home_group1%"); ifsrv60_has_to_restart=TRUE; if(winnt_query_service_status("OracleFormsServer-Forms60Server%oracle_home_group1%") == 4) service_running = FALSE;} ['NO_RESPONSE,'FILE_NOT_FOUND,'SERVICE_DOES_NOT_EXIST, 'INVALID_SERVICE_NAME, 'PERMISSION_DENIED: information_dialog(forms_server_running_msg); 'SERVICE_NOT_ACTIVE: service_running = FALSE; 'OS_ERROR: continue();] } } } } service_running = TRUE; if(exists(rwmts60_exe)) { while(service_running) { {copy_file(rwmts60_exe,temp_exe); move_file(temp_exe,rwmts60_exe); rwmts60_running = FALSE; service_running = FALSE;} ['PERMISSION_DENIED, 'OS_ERROR: rwmts60_running = TRUE;] if(rwmts60_running) { if((earlier_version(w32rmts60,"6.0.6.0.0"))||not(registered("w32rmts60"))) { information_dialog(reports_server_running_msg); } else { if(exists("%INSTALLER_HOME%\repname.cfg")) { reports__server_name = translate("reports_server_name", "%INSTALLER_HOME%\repname.cfg"); {winnt_stop_service("OracleReportServer-%reports__server_name%%oracle_home_group1%"); rwmts60_has_to_restart=TRUE; if(winnt_query_service_status("OracleReportServer-%reports__server_name%%oracle_home_group1%") == 4) service_running = FALSE;} ['NO_RESPONSE,'FILE_NOT_FOUND,'SERVICE_DOES_NOT_EXIST, 'INVALID_SERVICE_NAME, 'PERMISSION_DENIED: information_dialog(reports_server_running_msg); 'SERVICE_NOT_ACTIVE: service_running = FALSE; 'OS_ERROR: continue();] } else information_dialog(reports_server_running_msg); } } } } }