Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I am working with VSTO with C#. My worksheet has 10 Columns and many nows.
Some of the cell contains formula and other are populated with data from the data source.I define formating, formulas and fill in all cells with 0s (where there is no formula). I have to compute Meaid across the column for each row. When I load the data, it dictates whether I will have 2 or 4 or all 10 columns filled in. Once I load the data (lets say 4 columns), programatically I clear the remaining 6 columns. All works fine until this point. If I change some parameter and reload the data in the same session, and lets say it has (5 columns) more than 4 columns this time, all the cells , which had formula, for 5th columns, remains null. Data load is just fine. The reason for this issue is that when I cleared the 6 columns during my first data loas, it cleared my formula too. My quesitons is how can I maitain/keep the formula, which I set in the Excel, whiling Clearing the cell programtically. As I said I am using C# with VSTO and using Excel object model;s Range.Clear() method to clear the cell. Help greatly appreiciated!! -Sharad |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Clearing content from a cell (or a group) but retain its formula | Excel Discussion (Misc queries) | |||
Maintaining a formula in a cell when there was an insert row | Excel Discussion (Misc queries) | |||
Maintaining Formula after adding a new row | New Users to Excel | |||
clearing a cell and keeping the formula | New Users to Excel | |||
Copy a formula maintaining a constant cell | Excel Worksheet Functions |