I output RadGrid to Excel <Excel Format="Html"></Excel>
Here are my issues; (I have attached a picture to help illustrate my questions)
- Is there a way to know what row the Grid is currently writing to in Excel? Something like "Excel.CurrentRowNumber"?
Reason: I'm writing formulas to various cells during RadGrid1_ExcelExportCellFormatting but the first row of data it encounters gets written to Excel row 4 (because of the Grid Header). I tried using item.ItemIndex but that starts off at 0 (or 1 maybe, i don't recall). So my formulas are all messed up since I don't know what the current row in Excel is. I need to write out formulas like C4+D4 but I end up with C1+D1.
The problem gets worse as GroupByExpressions are encountered. Each time my data is grouped another 2 rows get written to Excel and now my current row is off by even more.
2. Is there a way to interact with the output to Excel when GroupByExpressions are encountered? I'd like to adjust the cells during that time such as inserting formulas to sum up all the rows in a section for each column. Same question regarding the GridFooterItem..? I'd like to put "grand total formulas" in those various columns.
3. I can't get rid of column A. There is a blank column that gets written out (see my picture). It seems to be known as "column" so I tried hiding it such as:
RadGrid1.MasterTableView.GetColumn("column").Display = false;
but no luck. This is only a minor annoyance, I could live with this as the formula questions above are the more important showstoppers.
Thank you!!