PDA

View Full Version : Won't let me call CreateProcess API function!!



NewsArchive
01-04-2002, 01:00 AM
I use IS6 Pro. The LaunchAppAndWait() command is worthless to me as I need
to launch processes that don't have any windows and then wait on them.
Installshield's knowledgbase has sample code for calling the Win32 API
functions CreateProcess() and WaitForSingleObject() directly (KB article
Q102879). This is the normal technique I use in my applications anyway, so
I thought that was good. The problem is, though, that the code won't link,
it generates the following linker error:

isrt.obl(AskDestPath.obs): error L8407: 'KERNEL32.CreateProcessA' :
conflicts with previous definition

The original prototype is as follows:

prototype BOOL KERNEL32.CreateProcessA ( LPSTR , STRING , LPSTR , LPSTR
, BOOL, INT , LPSTR , LPSTR , POINTER , POINTER );

I tried tweaking it, but no go. If I remove the prototype declaration from
my script, thinking IS's own files have it declared somewhere, then I get a
different error:

Process.rul(15): error C8025: 'CreateProcessA' : undefined identifier

Would someone please show how to get the sample code from KB Q102879 to
compile and link correctly?

NewsArchive
01-06-2002, 01:00 AM
http://www.installsite.org/cgi-bin/hse/HomepageSearchEngine.cgi?url=http://w
ww.installsite.org/pages/en/isp_ext.htm;geturl;terms=LaunchAppEx
"Remy Lebeau" <gambit47@gte.net> wrote in message
news:3c365b0e$1@news.installshield.com...
> I use IS6 Pro. The LaunchAppAndWait() command is worthless to me as I
need
> to launch processes that don't have any windows and then wait on them.
> Installshield's knowledgbase has sample code for calling the Win32 API
> functions CreateProcess() and WaitForSingleObject() directly (KB article
> Q102879). This is the normal technique I use in my applications anyway,
so
> I thought that was good. The problem is, though, that the code won't
link,
> it generates the following linker error:
>
> isrt.obl(AskDestPath.obs): error L8407: 'KERNEL32.CreateProcessA' :
> conflicts with previous definition
>
> The original prototype is as follows:
>
> prototype BOOL KERNEL32.CreateProcessA ( LPSTR , STRING , LPSTR ,
LPSTR
> , BOOL, INT , LPSTR , LPSTR , POINTER , POINTER );
>
> I tried tweaking it, but no go. If I remove the prototype declaration
from
> my script, thinking IS's own files have it declared somewhere, then I get
a
> different error:
>
> Process.rul(15): error C8025: 'CreateProcessA' : undefined identifier
>
> Would someone please show how to get the sample code from KB Q102879 to
> compile and link correctly?
>
>

NewsArchive
01-06-2002, 01:00 AM
http://www.installsite.org/cgi-bin/hse/HomepageSearchEngine.cgi?url=http://w
ww.installsite.org/pages/en/isp_ext.htm;geturl;terms=LaunchAppEx
"Remy Lebeau" <gambit47@gte.net> wrote in message
news:3c365b0e$1@news.installshield.com...
> I use IS6 Pro. The LaunchAppAndWait() command is worthless to me as I
need
> to launch processes that don't have any windows and then wait on them.
> Installshield's knowledgbase has sample code for calling the Win32 API
> functions CreateProcess() and WaitForSingleObject() directly (KB article
> Q102879). This is the normal technique I use in my applications anyway,
so
> I thought that was good. The problem is, though, that the code won't
link,
> it generates the following linker error:
>
> isrt.obl(AskDestPath.obs): error L8407: 'KERNEL32.CreateProcessA' :
> conflicts with previous definition
>
> The original prototype is as follows:
>
> prototype BOOL KERNEL32.CreateProcessA ( LPSTR , STRING , LPSTR ,
LPSTR
> , BOOL, INT , LPSTR , LPSTR , POINTER , POINTER );
>
> I tried tweaking it, but no go. If I remove the prototype declaration
from
> my script, thinking IS's own files have it declared somewhere, then I get
a
> different error:
>
> Process.rul(15): error C8025: 'CreateProcessA' : undefined identifier
>
> Would someone please show how to get the sample code from KB Q102879 to
> compile and link correctly?
>
>