Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
390
ExcelExporter (add non-grid elements)
posted

Is it possible using the WinGrid ExcelExporter to insert rows and text in an Excel document above the rows of exported data? I'd simply like at the top of a spreadsheet to insert a title, a short explanation of the data, and a date. Thanks for help.

Parents
No Data
Reply
  • 469350
    Verified Answer
    Offline posted

     Yes, this would be pretty easy. What you could do is handle the BeginExport event. The event arguments gives you all sorts of useful information like the WorkSheet, CurrentRow, and CurrentColumn. So you could use the worksheet.Rows collection to get the first (current) row and then set a Value on a cell in that row. And then increment the current row by 1 so that the first row in the grid begins exported on the second row of the sheet. 

Children
No Data