Pro grammatically Inserting data to Excel Sheet

  • Thread starter Thread starter cvsudheer
  • Start date Start date
C

cvsudheer

Hi All,
I am inserting data to an Excel sheet pro grammatically.
I use the following udpate command:

da.UpdateCommand = new OleDbCommand(@"UPDATE [Sheet1$] SET
[Description (QA)] = ? , [R&D Comments (Dev/Analysts)] = ? WHERE
[Defect ID] = ?", conn);
da.UpdateCommand.Parameters.Add("@Description (QA)",
OleDbType.VarChar, 255, "Description (QA)");
da.UpdateCommand.Parameters.Add("@R&D Comments (Dev/Analysts)",
OleDbType.VarChar, 255, "R&D Comments (Dev/Analysts)");

I cant use a value > 255.
Is there anyway to increase the limit?
 
Upgrade to Excel 2007. Prior versions were limited to 255 characters in a cell

Peter Richardson
 
I don't understand what you mean by cells being limited to 255 characters.
I'm reading these as Database commands mostly, which database data types may
very well have some limiting factors of how much can be stored as opposed to
Excel cells can handle 32,767 characters within a single cell, though only a
small portion of that would be visible from within the cell on the sheet.
This limit of cells is true of 97, 2000, 2002, and 2003.

--

Sincerely,

Ronald R. Dodge, Jr.
Master MOUS 2000

barnabel said:
Upgrade to Excel 2007. Prior versions were limited to 255 characters in a
cell

Peter Richardson

Hi All,
I am inserting data to an Excel sheet pro grammatically.
I use the following udpate command:

da.UpdateCommand = new OleDbCommand(@"UPDATE [Sheet1$] SET
[Description (QA)] = ? , [R&D Comments (Dev/Analysts)] = ? WHERE
[Defect ID] = ?", conn);
da.UpdateCommand.Parameters.Add("@Description (QA)",
OleDbType.VarChar, 255, "Description (QA)");
da.UpdateCommand.Parameters.Add("@R&D Comments (Dev/Analysts)",
OleDbType.VarChar, 255, "R&D Comments (Dev/Analysts)");

I cant use a value > 255.
Is there anyway to increase the limit?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top