Results 1 to 6 of 6

Thread: [RESOLVED] launching excel from asp.net app

Threaded View

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Jul 2005
    Location
    In A House :)
    Posts
    291

    Resolved [RESOLVED] launching excel from asp.net app

    i have an app that outputs a gridview to excel spreadsheet and adds a couple of rows for accounting.

    i'm trying to launch the spreadsheet after its saved off, using

    Code:
                excelApp.ActiveWorkbook.SaveAs(filename);
                excelApp.ActiveWorkbook.Saved = true;
                excelApp.Quit();
                var si= new ProcessStartInfo {FileName = filename, UseShellExecute = true}; //hits here and crashes
                Process.Start(si);
    it hits the marked line and crashes that it cant find the file, its automatically saving it to the documents folder on my local machine, and i cant seem to get it to save elsewhere (i have a data directory in the project i use for the other file types) that i would like to save to if possible, but it seems that if you have office installed it don't like it. i could always copy the file from documents to the datastore, but that's a pain in the backside.

    so how do i launch excel application using the file i just saved off to show to the bean crunchers? VB examples will work as well, i can translate
    Last edited by DirtyHowi; Apr 17th, 2013 at 11:40 AM.
    --"Tap Dancing On The Brittle Edge Of Sanity"--

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width