Dreaded 911 cell character limitation
Hello everyone, I have a C# method that uses an object array to programmatically populate an Excel spreadsheet. The problem I’m faced with is a 0x800A03EC abend when trying to add more than 911 characters to a single cell. ********* Code snippet that creates the array foreach(DataRow row in MyDataTable.Rows) { col_index=0; foreach(object item in row.ItemArray) { //create an array of row values. objData[row_index,col_index] = item.ToString(); col_index++; } row_index++; } ********* Code snippet that populates the spreadsheet objRange.Value2 = objData; //this is where the error occurs //objRange.set_Value(Missing.Value, objData); //tried this… same error I've been searching the www for an answer and the only solution I can find is to truncate the string to 911 characters. I would prefer to not take this approach if I don't have to. I have to believe there is a way to programmatically add more than 911 characters because I'm able to manually copy 32k characters into an excel spreadsheet cell. Has anyone else overcome this problem? -- mdengler ------------------------------------------------------------------------ mdengler's Profile: http://www.excelforum.com/member.php...o&userid=32030 View this thread: http://www.excelforum.com/showthread...hreadid=517803 |
All times are GMT +1. The time now is 10:35 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com