Monday, March 26, 2012

ShellExecute command for ASP.NET?

Is there an equivalent ShellExecute() command (like in VB/VC apps) for
opening up Excel files from within ASP.NET web application.
I create an Excel format of a crystal report. I'd like to next open this up
in separate process from ASP.NET web app.Not really. You can potentially write a client VB script that might be able
to execute some such thing but you will need a *lot* of privileges on that
client box to do that.
More over, having an ASP.NET web app do this is not very good idea. You
might want re-consider what you would like to do.
Girish Bharadwaj
http://msmvps.com/gbvb
"DavidS" <DavidS@.discussions.microsoft.com> wrote in message
news:744EC249-3769-4D73-A216-8E9B53650979@.microsoft.com...
> Is there an equivalent ShellExecute() command (like in VB/VC apps) for
> opening up Excel files from within ASP.NET web application.
> I create an Excel format of a crystal report. I'd like to next open this
up
> in separate process from ASP.NET web app.
Do you want to open the Excel file client side or server side ?
Server side you could use the Process class would do it, but this is
generally not recommended.
Client side, just have a link or stream the file to the browser...
Patrice
"DavidS" <DavidS@.discussions.microsoft.com> a crit dans le message de
news:744EC249-3769-4D73-A216-8E9B53650979@.microsoft.com...
> Is there an equivalent ShellExecute() command (like in VB/VC apps) for
> opening up Excel files from within ASP.NET web application.
> I create an Excel format of a crystal report. I'd like to next open this
up
> in separate process from ASP.NET web app.
DavidS wrote:

> Is there an equivalent ShellExecute() command (like in VB/VC apps)
> for opening up Excel files from within ASP.NET web application.
> I create an Excel format of a crystal report. I'd like to next open
> this up in separate process from ASP.NET web app.
I'm assuming you want Excel launched on the client computer, right?
Do some web searches for the Office Web Components (OWC).
Eric
I've done research and use COM Interop to faciliate communication.
Basically - I get a permission issue when I run this on the IIS
server.Error: Exception of type System.Web.HttpUnhandledException was thrown
.
Access is denied.
sample code...
Dim ExcelObj As New Excel.ApplicationClass() - get permission problem here!
Dim ExcelDoc As Excel.Workbooks
ExcelDoc = ExcelObj.Workbooks
ExcelDoc.Open( _ExcelFile )
ExcelObj.Visible = True
Again - I don't want to have <identify impersonate="true"> in web config
file. Is there a solution
"Eric" wrote:

> DavidS wrote:
>
> I'm assuming you want Excel launched on the client computer, right?
> Do some web searches for the Office Web Components (OWC).
> Eric
>

0 comments:

Post a Comment