SpreadsheetGear 2012
FormulaR1C1 Property (IRange)
Example 






Gets or sets the value or formula of the cells represented by this IRange using ReferenceStyle.R1C1.
Syntax
'Declaration
 
Property FormulaR1C1 As System.String
'Usage
 
Dim instance As IRange
Dim value As System.String
 
instance.FormulaR1C1 = value
 
value = instance.FormulaR1C1
System.string FormulaR1C1 {get; set;}
read-write property FormulaR1C1: System.String; 
function get,set FormulaR1C1 : System.String
__property System.string* get_FormulaR1C1();
__property void set_FormulaR1C1( 
   System.string* value
);
property System.String^ FormulaR1C1 {
   System.String^ get();
   void set (    System.String^ value);
}
Remarks
To put a formula in a cell, the first character must be '='. Otherwise, attempts will be made to convert the specified string to a number, date, time, date/time, logical or error value. If none of these succeed, the value will be set in the cell as text.
Example
// Set cells to a formula which referes to the top-left cell in the worksheet.
range.FormulaR1C1 = "=R1C1";
' Set cells to a formula which referes to the top-left cell in the worksheet.
range.FormulaR1C1 = "=R1C1"
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

IRange Interface
IRange Members
Formula Property

Send Feedback