cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Rachelbaskaran
Level 5

Restart an application- Installshield 2009

Hey,

I'm building a installer where I have the Apache exe file. I wrote a couple of script to control few aspects of my installer.

Now I have one issue, I need to delete the httpd.conf( hope so the extension is .conf) which is in the apache and copy my http.conf to apache\\apache2\\conf and RESTART my apache monitor.

Hope I can do the delete part with the below script:

if(DeleteFile(DEL_DIR ^ DEL_FILE) < 0) then
MessageBox("Delete failed.", SEVERE);
else
MessageBox("File Deleted.", INFORMATION);
endif;


Is there a script that helps me to RESTART apache monitor once the httpd.conf is copied to apache?

Thanks
Rachel
Labels (1)
0 Kudos
(22) Replies
gavin_landon
Level 6

Based on:
http://helpnet.acresso.com/robo/projects/installshield11langref/SERVICE_PARAMS.htm

SERVICE_IS_PARAMS only works with OpenSCManager, CreateService, or ChangeServiceConfig calls.

ServiceStartService should stop the service and restart it. Using ServiceStopService then ServiceStartService, just allows you to verify it stopped. You were wanting to see if stop from the orginal posting, correct?

I'm going to need a recap of where your are. I'm starting to think back and look at the postings up to this point and I'm not sure where the problem is anymore. If your saying that the Service isn't stopping at all when ServiceStopService is being called, then there is a problem with your install. I would try reinstalling InstallShield. Originally you said that if you have a messagebox between ServiceStopService and ServiceStartService everything works, but your also saying that you don't see it stop without the MessageBox. Does that mean it's not stopping or you just dont see it stopping? So I'm unclear where the problem is.
0 Kudos
Rachelbaskaran
Level 5

Hey Gavin,

Thanks for your reply. No worries, I figured out the problem. Actually in my PID(httpd) file the document root was Apache\Apache2\Example_TEST. But inside my apache I had renamed the file Example_TEST to Example_TEST1. So I had to change the TEST to TEST1 in httpd and then the restarting worked.


Thanks again
Rachel
0 Kudos