Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

HTTPApp CreateProcess Excel

Status
Not open for further replies.

sijgs

Programmer
Dec 29, 2001
100
CA
I am trying to do a createprocess from a web application I wrote in D6. Given the correct input from the web page, I want to start Excel and pass it two files.

In a test window app the code works fine, under the web app Excel starts, but puts up NO WINDOW, accomplishes NOTHING and JUST SITS there. By the way, yes, Excel is coded to do its reports and then Application.quit so it completely goes away by itself.

It's got to be something to do with "inheritance" and the fact that the web application doesn't have a window.

So does anyone know what the trick is to get this to work?

DW := 0;
LB := False;
LP := nil;
FillChar(TS, SizeOf(TS), 0);
FillChar(TP, SizeOf(TP), 0);
FillChar(Parm, SizeOf(Parm), 0);
Parm := 'EXCEL.EXE STORE6.XLS GC_REPORTS.XLS';
PParm := @Parm[1];
If (CreateProcess(nil, PParm, nil, nil, LB, DW, LP,
nil, TS, TP)= False) Then
Begin
{ code to document error }
End;

Hope someone can help
Thanks
JGS
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top