T.R | Title | User | Personal Name | Date | Lines |
---|
5631.1 | Net command may work | CANDOO::GRIEB | | Mon Feb 03 1997 09:55 | 4 |
|
system("net start service_name"); ?????
|
5631.2 | | REGENT::N2ITIV::LEE | Andy Lee (Park facing out) | Mon Feb 03 1997 11:19 | 8 |
|
Check out OpenService() and StartService()
-Andy
|
5631.3 | | 8153::tecotoo.mro.dec.com::mayer | Danny Mayer | Mon Feb 03 1997 11:24 | 6 |
| > Check out OpenService() and StartService()
Under the current version of InstallShield, you'd have to write a DLL
to make these calls to do this. Not hard, just a pain.
Danny
|
5631.4 | | CRONIC::LEMONS | And we thank you for your support. | Mon Feb 03 1997 11:35 | 6 |
| Hmm. I only have InstallShield SDK and the time-bombed version of
InstallShield Express available. Can I write a DLL using either one of
these?
Thanks!
tl
|
5631.5 | | 8153::tecotoo.mro.dec.com::mayer | Danny Mayer | Mon Feb 03 1997 12:47 | 9 |
| > Hmm. I only have InstallShield SDK and the time-bombed version of
> InstallShield Express available. Can I write a DLL using either one of
> these?
I can't answer that. What does the SDK Documentation say? I have the
full professional version and it's documented how to do it. The SDK version
may not allow you to do that.
Danny
|
5631.6 | InstallShield CallDLLFx() is in SDK vers | COOKIE::KELLER | | Mon Feb 03 1997 14:00 | 19 |
| Having just done this, I can state that it is possible to call a DLL from
the InstallShield SDK version to start a Windows NT service. Some
things to watch:
Make sure your DLL functions are declared as required by
InstallShield SDK version.
Verify they are correctly exported in the DLL, use NT explorer 'quick
view' function to check the exports. Also, make sure the DLL name
is in upcase (I ended up needing a linker DEF file to force correct
attributes)
If the DLL is not setup correctly, you will just get a -1 back from
InstallShield CallDLLFx() with no other info.
Feel free to send me mail and I can send you some code if needed, good
luck.
Greg
|
5631.7 | | CRONIC::LEMONS | And we thank you for your support. | Mon Feb 03 1997 19:04 | 16 |
| Hi
Thanks, all, for this dialogue. It's very helpful.
Please talk down to me; I'm not a C++ programmer. In another life, I
was COBOL programmer, so doing this task may be beyond what I should be
attempting.
That said, how do I create a DLL? Do I need to create some C++ code to
do this? Thanks to those who poasted the calls, I've sorta got any
idea of the Win32 API machinery I need. But I don't know how to create
the DLL that will include it.
Thanks, again, for any help!
tl
|
5631.8 | | 8153::tecotoo.mro.dec.com::mayer | Danny Mayer | Tue Feb 04 1997 06:08 | 23 |
| > Hi
>
> Thanks, all, for this dialogue. It's very helpful.
>
> Please talk down to me; I'm not a C++ programmer. In another life, I
> was COBOL programmer, so doing this task may be beyond what I should be
> attempting.
>
> That said, how do I create a DLL? Do I need to create some C++ code to
> do this? Thanks to those who poasted the calls, I've sorta got any
> idea of the Win32 API machinery I need. But I don't know how to create
> the DLL that will include it.
>
> Thanks, again, for any help!
>
> tl
I don't think anyone needs to talk down to you. I do think someone
should provide you with the C++ code to make this happen along with the
file to make this a DLL. Maybe someone can post this. It's a useful
set of functions to have around for installations.
Danny
|
5631.9 | | CRONIC::LEMONS | And we thank you for your support. | Tue Feb 04 1997 09:22 | 14 |
| Actually, thanks to Danny's help, I know now that a NT service can be
started with the command:
NET START servicename
So, rather than seek a DLL that specifically works with a service, I
now would like to find a generic DLL that would take a command (like
NET START servicename), execute it, wait until it was done (maybe this
could be a option) and return a status code.
Does this exist?
Thanks!
tl
|