cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
samsal
Level 4

InstallShiled Automation interface 12 with windows services

Hi,
Im having this problem that I hope you can help me with:
I have windows service project that interface with InstallShield Automation Interface through adding a reference to the ISWiAutomation14.dll that comes under the "Macrovision\IS2008\System" folder. Everything works fine intially and the project compiles and I'm able to install the service and have it start running. The problem is when I decide to un install the servce through the setup project and compile again I get a compilation error claiming that the name space ISWiAuto14 can't be found anymore even though the dll still there in the project. When I remove the dll and refernce it again, I get a message Box error claiming that " The dll is not accessible and/or the "ISWiAutomation14.dll" is not valid dll or COM component !
Can you please help me to figure how to fix this problem or to avoid it in the future everytime I install and un install my windows service.
Thanks ahead
Labels (1)
0 Kudos
(4) Replies
RobertDickau
Flexera Alumni

Is this a service that's running on your development system? (I don't think the IswiAutomation DLL is supposed to be redistributed, so it shouldn't be running on any other system, of course.) If so, could you post more information about what you're installing and how you're calling the DLL?
0 Kudos
samsal
Level 4

Hi Robert,
Thanks for the reply.
The dll is included in the windows service project itself. I just add it as a reference there to my project and then include it in my code as
"using ISWiAuto14". After that I have access to all the automation interface objects Such as ISWiProject, and u know how when u want to install the windows service u have to add a setup project to it that will enable you to install and/or uninstall the service. As I said everything compiles and run correctly when I install the service for the first time, the problem happen when I decide to un install the service. As for now Im running everything locally.
0 Kudos
RobertDickau
Flexera Alumni

I'm still not clear where the error occurs; are you uninstalling something that unregisters the Automation interface's COM classes? Does your project have the Automation COM DLL in it (it shouldn't)?
0 Kudos
samsal
Level 4

Hi Robert,

Here is what Im doing in steps, hopefully that we clearify my my problem more:
Note: "Im using Visual Studio 2005"

1- Create Visual Studow Windows Service Project.
2- Define a class called IsntalledShieldPackage that will uses the interface. This class will be used by the windows serivce to create a package everytime the windows service is running.
3- right click on the project reference and click on add reference.
4- I browse the automation interface dll which can be found under the installation location, e.g. "C:\Program Files\Macrovision\IS2008\System" as installed on my machine.
5- I click on "ISWiAutomation14.dll" to add it as a reference to my project.
6- after adding the reference, the following refernces will show in my project referece:
ISAPPSERVICESLib
IsmAutoLib
ISMMUpdaterLib
ISUPGRADELib
ISWiAuto14
ISWIBUILDLib
7- I add a Setup project to the solution. This project will be responsible in installing the project servcice in the windows services.

As I said initially when I compile everything for the first time. every thing s compiles succesfully and Im able to install the created service to the windows services with no problem. The problem happen when I decide to Un install the service, when that happen and go back the prject or even any seperate project that uses the same dll, the compilation fails claming that namesapce "ISWiAuto14" cannot be found even I still can see it under the project references. Even when I try to remove the reference and add it again I get an error message saying that " the dll is not accessable or its not a valid dll or COM component".
I noticed that not until I Un install the whole installshield and Re install it again, then I can re add the dll again and everything compiles.

I hope that clearify the problem Im facing, If you still having diffculty understanding you can try to create simple windows service project and add the same dll to it and create simple package in the service, then install the service and run it and un install it and then go back to the project and try to compile.
Let me know your finding.
Thanks
0 Kudos