Get Started
Usage API
More information

GetOrientation

GetOrientation() → { Angle }

Returns the range angle.

Parameters:

This method doesn't have any parameters.

Returns:

Type
Angle

Example

Copy code
builder.CreateFile("xlsx");
oWorksheet = Api.GetActiveSheet();
oWorksheet.GetRange("A1").SetValue("1");
oWorksheet.GetRange("B1").SetValue("2");
oRange = oWorksheet.GetRange("A1:B1");
oRange.SetOrientation("xlUpward");
sOrientation = oRange.GetOrientation();
oWorksheet.GetRange("A3").SetValue("Orientation: " + sOrientation);
builder.SaveFile("xlsx", "GetOrientation.xlsx");
builder.CloseFile();

Resulting document