How to export view into Excel sheet in web?

Hi

I am into the development of web based application. I got to export the view into Excel sheet. Besides that I need to present the chart into excel sheet based on the user inputs. Any help would be apprecaited.

Thanks

Pankaj Kumar.D

Subject: How to export view into Excel sheet in web?

Pankaj

Take a look at

http://www.codestore.net/store.nsf/unid/EPSD-5VBS6Y?OpenDocument

and look at the section headed

‘Make views exportable to Excel’

HTH

Tim

Subject: RE: How to export view into Excel sheet in web?

Thanks for your quick response.

Cheers

Pankaj

Subject: How to export view into Excel sheet in web?

’ You need to create Lotus Script agent and pass the view name ( alias is preferred ) while calling it.’ In the agent grab the view name and using the NotesViewEntryCollection class and NotesViewEntry class

’ you can get the values in the view.

’ Loop through the collection of ViewEntries and print the excel sheet as required

Print {<SCRIPT LANGUAGE="JScript">}

Print {var ExcelObj = new ActiveXObject("Excel.Application")}

Print {ExcelObj.Visible = true}

Print {var oWB = ExcelObj.Workbooks.Add()}

Print {var ExcelActiveSheet=oWB.ActiveSheet}



Print{ ExcelActiveSheet.cells(1, 1).value ="} + "YOURVIEWNAME" + {";}

Print{ ExcelActiveSheet.cells(1, 1).font.size = 12; }

Print{ ExcelActiveSheet.cells(1, 1).font.bold = true; }

’ Put your loop here and format the contents as required.

’ For more help on formatting content, check the marco in Excel for the objects.

Print {ExcelObj.Visible = true}

Print {ExcelObj.UserControl = true}	

Print {var xlFileName = ExcelObj.GetSaveAsFilename("} + "YOURFILENAME" + {", "Excel files (*.XLS), *.XLS");}

Print {if (xlFileName != "")}

Print {oWB.Saveas(xlFileName)}

Print {</SCRIPT>}

base code is here, u can build on this.

cheers!!

Subject: RE: How to export view into Excel sheet in web?

I am developing a web based application on Domino 6.01 and I have some questions.

  1. Do I need 6.5 to do this?

  2. Does Excel need to be installed at either the server or client? My system does nothing when I execute the above script. I don’t get a file save dialog.

  3. Can you give more detail on where to find the information about formatting?

Thanks in advance.