Click or drag to resize
SheetOpenCell Method
Opens the specified cell and returns a Cell object.

Namespace: Aceoffix.ExcelWriter
Assembly: Aceoffix (in Aceoffix.dll) Version: 5.0.0.1
Syntax
public Cell OpenCell(
	string CellAddress
)

Parameters

CellAddress
Type: SystemString

The A1-style notation is defined in Microsoft Excel. For example: "A1".

Note Note

Note: There is a limit that the maximum number of columns per worksheet is 676 and the maximum number of rows is 65,536 in Excel2003 and earlier versions. Please do not exceed the maximum number of columns when input the parameter of CellAddress.

Return Value

Type: Cell
Returns a Cell object.
Remarks
Opens the specified cell and returns a Cell object.
Examples
The following code example shows how to call the OpenCell method.
Aceoffix.ExcelWriter.Workbook wb = new Aceoffix.ExcelWriter.Workbook();
Aceoffix.ExcelWriter.Sheet sheet1 = wb.OpenSheet("sheet1");

// Output data into the cell and set the color of the cell.
sheet1.OpenCell("C2").Value = "Acesoft";
sheet1.OpenCell("C2").ForeColor = System.Drawing.Color.Yellow;
sheet1.OpenCell("C2").BackColor = System.Drawing.Color.Red;

sheet1.OpenCellRC(2, 4).Value = "Aceoffix";

sheet1.OpenCell("B5").Value = "6";
sheet1.OpenCell("C5").Value = "3";
sheet1.OpenCell("D5").Formula = "B5+C5";

AceoffixCtrl1.ServerPage = "aceoffix-runtime/server.aspx";
AceoffixCtrl1.Bind(wb);
AceoffixCtrl1.OpenDocument("doc/test.xls", Aceoffix.OpenModeType.xlsReadOnly, "Tom");
See Also