Export to Excel

Results 1 to 3 of 3

Thread: Export to Excel

  1. #1
    Jon Guest

    Default Export to Excel

    I&#039;m creating some management reports on a site I&#039;m developing at the moment and I was wondering how to go about exporting the reports to an MS Excel spreadsheet.<BR>Thank You.

  2. #2
    Priyan Guest

    Default RE: Export to Excel

    Hi,<BR>Try this sample code.<BR><BR>&#060;input type="text" name="ROW1" size="52"&#062;<BR><BR>&#060;input type="text" name="ROW2" size="52"&#062;<BR><BR>&#060;INPUT TYPE="SUBMIT" NAME="Btn1" VALUE="Click to Update!"&#062;<BR><BR><BR>&#060;SCRIPT LANGUAGE="VBScript"&#062;<BR>&#060;!--<BR>Dim ExcelSheet<BR>Set ExcelSheet = CreateObject("Excel.Sheet")<BR><BR>Sub btn1_ONCLICK()<BR>ExcelSheet.Application.Visible = True<BR>ExcelSheet.ActiveSheet.Cells(1,1).Value = ROW1.VALUE<BR>ExcelSheet.ActiveSheet.Cells(2,1).Va lue = ROW2.VALUE<BR>ExcelSheet.SaveAs "YourFile.xls"<BR>ExcelSheet.Application.Quit<BR>S et ExcelSheet = Nothing<BR>End Sub<BR>

  3. #3
    Jon Guest

    Default RE: Export to Excel

    I have got this to work on the client side but it doesn&#039;t seem to work server side. Also, when I export the data to excel i want to let the managers preview the spreadsheet and than decide wheather thay want to save it or not.<BR>Thanks for you help.

Posting Permissions

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