Running a Windows APP from ASPX page

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Is it possible to execute a C# Windows app from an ASPX (C#) web application.

My app runs over the Intranet and on one page I want to run a C# program
which does some things I can't do from the web.

The program runs (via a javascript) like this:

Page.RegisterStartupScript("xx","<script>windows.href=abc.exe</script>")

The program runs, but when I exit and return to the Web App, I get a CGI
Error.

CGI Application misbehaved. Something about incomplete HTTP headers.

Is there a way around this? A better way to launch the program?

Thanks.
 
Hi Andy,
My app runs over the Intranet and on one page I want to run a C# program
which does some things I can't do from the web.

Like what?
The program runs, but when I exit and return to the Web App, I get a CGI
Error.

CGI Application misbehaved. Something about incomplete HTTP headers.

This is not specific to Windows or .NET, you tend to get this error if
you've sent a stream to a browser without setting up the headers
correctly. If you're EXE has output, you need to make sure it's HTTP
compliant.
 
My windows app launches WORD, reads in a document and merges it with the data
record selected by the user. It then sends the document back to the web app
and closes Word. I looked into Automation over the web but had trouble doing
that as well.

Launching the program from the internet, I get ACCESS DENIED when the
program tries to start WORD. After reading the help, newsgroups, etc, I
concluded that this wasn't the best method. I did try the DMCNG (something
like that) to let office start from Web app, but it didn't change anything.

My EXE does not have any screen output. It opens, makes the file, saves it
and closes. How to I make it HTTP compliant?
and how should I launch the application? Is the Page.RegStartupScript the
best method?

Thanks.
 
Back
Top