Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Excel cell by cell writing.
int ePointer = ir.GetEntryPointer();
Xl.Worksheet sheet = (Xl.Worksheet)DotNetInsFunctions.xlApp.Worksheets[ir.GetInfo().Sheet]; while(ePointer = 0) { Entry e = ir.GetEntry(ePointer); Xl.Range cell = (Xl.Range)sheet.Cells[e.row,e.column]; cell.Value2 = e.initValue; ePointer = ir.GetEntryPointer(); } In the above code, if the while loop executes for 10,000 cells, it takes 300sec to write values to 10,000 cells. If I want to do a cell by cell writing, this is how slow it is performing.. Does anyone know of any other effective and fast way of writing stuff to sheet in a cell by cell manner. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Excel cell by cell writing.
Hi,
where is the data comming from? Normally we would For each cell in Range("A1:A10000") cell = x Next cell but there are lots of ways to speed this up depending on where the data is and where you want to put it. -- Thanks, Shane Devenshire "gutta" wrote: int ePointer = ir.GetEntryPointer(); Xl.Worksheet sheet = (Xl.Worksheet)DotNetInsFunctions.xlApp.Worksheets[ir.GetInfo().Sheet]; while(ePointer = 0) { Entry e = ir.GetEntry(ePointer); Xl.Range cell = (Xl.Range)sheet.Cells[e.row,e.column]; cell.Value2 = e.initValue; ePointer = ir.GetEntryPointer(); } In the above code, if the while loop executes for 10,000 cells, it takes 300sec to write values to 10,000 cells. If I want to do a cell by cell writing, this is how slow it is performing.. Does anyone know of any other effective and fast way of writing stuff to sheet in a cell by cell manner. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Need sample for reading value from and writing value to cell E53 from outside Excel | Excel Discussion (Misc queries) | |||
Need sample for reading value from and writing value to cell E53 from outside Excel | Excel Programming | |||
writing a formular into one cell of an excel sheet | Excel Programming | |||
Writing many lines on a same Excel 2000 cell | Excel Discussion (Misc queries) | |||
Writing Excel Formula To A Cell | Excel Programming |