Results 1 to 1 of 1

Thread: Display Excel Spreadsheet On Web Page

Threaded View

  1. #1

    Thread Starter
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Display Excel Spreadsheet On Web Page

    I need to take an Excel spreadsheet and display it on a web page. The spreadsheet needs to retain all Excel functionality. I'll worry about that after I solve the problem of actually displaying it. I searched this section, as well as the web in general, and pieced together the following code that seems to work well for other people, but is giving me an error.
    Code:
    <html><head>
    
    <script language=vbscript>
    
    Dim objExcel
    Dim oxlBook
    
    Sub chartsheet_onclick()
    call OpenWorkbook("PathToMySpreadsheetOnNetworkFileServer\MySpreadsheet.xls")
    End Sub
    
    Sub OpenWorkbook(strLocation)
    
    Set objExcel = CreateObject("Excel.Application")
    
    Set oxlBook = objExcel.Workbooks.Open(strLocation, false, true)
    objExcel.Visible = true
    
    objExcel.UserControl = true
    objExcel.Sheets("Issue_List").Visible = True
    End Sub
    
    </script>
    
    <title></title></head><body><br>
    
    this is a test page for displaying an excel spreadsheet
    <br><br>
    
    <input type=button name=chartsheet value="display excel spreadsheet">
    
    </body></html>
    The error I get is "ActiveX Object Can Not Create Excel.Application" - Yet, I see the exact same code in example after example after example. Is there something behind the scences that I am not aware of?
    Attached Images Attached Images  

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