Facing Problems in exporting notes to excel

Hi I am exporting the fields to Excel,and finding it very intersting,but facing many problems.

My Requirements are

1)Export the data to Excel(Some what it’s a Report)

2)Create the charts from the data exported.

Currently I am on point no 1

What is Required here the data should be exported,and we should only give the starting cell,it should automatically export the data

in rows and columns.I am able to export the data by hard coding the cell address,but i need it should export data automatically in Rows and columns

For Reference i am pasting my code.

n=1

Do While Not doc Is Nothing 

	

	B=1

	

	datetime.LSLocalTime=doc.logged(0)

	

	

	efromD.LSLocalTime=thisdoc.efromD(0)

	etoD.LSLocalTime=thisdoc.etoD(0)

	

	If  dateTime.DateOnly>=efromD.dateonly Then

		If  dateTime.DateOnly<=etoD.dateonly Then		

			n = n + 1(N is used for column Address)	

'Printing the Column Heading in the Cells

			excelApp.sheets(1).range("A" & Cstr(3)).value = "Breakup of IS Requests for the Month Of-----"

			excelApp.Selection.ColumnWidth = 15

			excelApp.Range("A3").Font.Bold = True

			excelApp.Range("A3").Font.ColorIndex = 1

			

			

			excelApp.sheets(1).range("B" & Cstr(n)).value = doc.r_category(0)(Here hard coding the cell names,but need the cell names should appear

Programtically,as the data is not fixed always ,it keep on increasing or decreasing)

			Assigned=doc.r_assignedto(0)+doc.r_category(0)

			Set doc1=view.getdocumentbykey(Assigned)

			Set vc = view.GetAllEntriesByKey(Assigned)

			B=vc.count

			

			

			

			excelApp.sheets(1).range("B" & Cstr(n)).value = B	

			

			

			excelApp.sheets(1).range("C" & Cstr(n)).value = doc.r_assignedto(0)	

		End If

	End If

	

	

	

	

	Set doc = view.getnextdocument(doc)

Loop

Call excelApp.save

excelApp.ActiveWorkBook.close

Call excelApp.quit

Subject: Facing Problems in exporting notes to excel

If I were you I’d follow the example in the sandbox here: http://www-10.lotus.com/ldd/sandbox.nsf/ByDateNJ/42953CEBB6C9A39488256AF40051D674/$FILE/ExportToExcel.txt?OpenElement

It’s how I do this as well, you can use variables for the column also (the example uses variables for rows only, although this is of course the most common)

Dan

Subject: RE: Facing Problems in exporting notes to excel

Thanks Dan But this case is not suitable for my requirements.

My application is Support Desk,there are request which log on the database,now i need the request to be exported,and these requets are not fixed,

So i can’t hard code the row numbers.

Subject: RE: Facing Problems in exporting notes to excel

I’m confused - what the example specifically does is not hard code the row numbers. That’s what you’re asking for isn’t it?

Dan

Subject: RE: Facing Problems in exporting notes to excel

Yes