Files
Common-VS2019/SacsStandardData/Data/Excel/SaMsSpreadsheet-Dfn.cs
T

207 lines
6.5 KiB
C#

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Sarand.Net.Standard.Data.Excel
{
//=======================================================================
// Definitions.
public enum SaExcelLogicalUnit
{
Point,
Pixel,
Cm,
Inch,
//CharWidth, // Not supported.
};
//=======================================================================
/// <summary>Spreadsheet file format.
/// <para>Ref. Microsoft.Office.Interop.Excel.XlFileFormat</para></summary>
public enum SaXlFileFormat
{
Default = 0,
/// <summary>Without macro's in 2007-2013 [xlsx]. Value: 51.</summary>
OpenXMLWorkbook = XlFileFormat.xlOpenXMLWorkbook,
/// <summary>With or without macro's in 2007-2013 [xlsm]. Value: 52.</summary>
OpenXMLWorkbookMacroEnabled = XlFileFormat.xlOpenXMLWorkbookMacroEnabled,
/// <summary>Excel Binary Workbook in 2007-2013 with or without macro's [xlsb]. Value: 50.</summary>
Excel12 = XlFileFormat.xlExcel12,
/// <summary>97-2003 format in Excel 2007-2013 [xls]. Value: 56.</summary>
Excel8 = XlFileFormat.xlExcel8,
/// <summary>CSV format. Value: 6.</summary>
CSV = XlFileFormat.xlCSV,
};
/// <summary>
/// Specifies the page orientation when the worksheet is printed.
/// <para>Ref. Microsoft.Office.Interop.Excel.XlPageOrientation</para>
/// </summary>
public enum SaXlPageOrientation
{
NotSpecified = int.MinValue,
xlPortrait = XlPageOrientation.xlPortrait,
xlLandscape = XlPageOrientation.xlLandscape
}
/// <summary>
/// Specifies the weight of the border around a range.
/// <para>Ref. Microsoft.Office.Interop.Excel.XlBorderWeight</para>
/// </summary>
public enum SaXlBorderWeight
{
NotSpecified = int.MinValue,
Hairline = XlBorderWeight.xlHairline,
Thin = XlBorderWeight.xlThin,
Medium = XlBorderWeight.xlMedium,
Thick = XlBorderWeight.xlThick
}
/// <summary>
/// Specifies the line style for the border.
/// <para>Ref. Microsoft.Office.Interop.Excel.XlLineStyle</para>
/// </summary>
public enum SaXlLineStyle
{
NotSpecified = int.MinValue,
None = XlLineStyle.xlLineStyleNone,
Double = XlLineStyle.xlDouble,
Dot = XlLineStyle.xlDot,
Dash = XlLineStyle.xlDash,
Continuous = XlLineStyle.xlContinuous,
DashDot = XlLineStyle.xlDashDot,
DashDotDot = XlLineStyle.xlDashDotDot,
SlantDashDot = XlLineStyle.xlSlantDashDot,
}
/// <summary>
/// Specifies the interior pattern of a chart or interior object.
/// <para>Ref. Microsoft.Office.Interop.Excel.XlPattern</para>
/// </summary>
public enum SaXlPattern
{
NotSpecified = int.MinValue,
/// <summary>No pattern.</summary>
None = XlPattern.xlPatternNone,
/// <summary>Excel controls the pattern.</summary>
Automatic = XlPattern.xlPatternAutomatic,
/// <summary>8% gray.</summary>
Gray8 = XlPattern.xlPatternGray8,
/// <summary>16% gray.</summary>
Gray16 = XlPattern.xlPatternGray16,
/// <summary>25% gray.</summary>
Gray25 = XlPattern.xlPatternGray25,
/// <summary>50% gray.</summary>
Gray50 = XlPattern.xlPatternGray50,
/// <summary>75% gray.</summary>
Gray75 = XlPattern.xlPatternGray75,
/// <summary>75% dark moiré.</summary>
SemiGray75 = XlPattern.xlPatternSemiGray75,
/// <summary>Solid color.</summary>
Solid = XlPattern.xlPatternSolid,
/// <summary>Dark vertical bars.</summary>
Vertical = XlPattern.xlPatternVertical,
/// <summary>Dark horizontal lines.</summary>
Horizontal = XlPattern.xlPatternHorizontal,
/// <summary>Dark diagonal lines running from the lower left to the upper right.</summary>
Up = XlPattern.xlPatternUp,
/// <summary>Dark diagonal lines running from the upper left to the lower right.</summary>
Down = XlPattern.xlPatternDown,
/// <summary>Checkerboard.</summary>
Checker = XlPattern.xlPatternChecker,
/// <summary>Light horizontal lines.</summary>
LightHorizontal = XlPattern.xlPatternLightHorizontal,
/// <summary>Light vertical bars.</summary>
LightVertical = XlPattern.xlPatternLightVertical,
/// <summary>Light diagonal lines running from the upper left to the lower right.</summary>
LightDown = XlPattern.xlPatternLightDown,
/// <summary>Light diagonal lines running from the lower left to the upper right.</summary>
LightUp = XlPattern.xlPatternLightUp,
/// <summary>Grid.</summary>
Grid = XlPattern.xlPatternGrid,
/// <summary>Criss-cross lines.</summary>
CrissCross = XlPattern.xlPatternCrissCross,
LinearGradient = XlPattern.xlPatternLinearGradient,
RectangularGradient = XlPattern.xlPatternRectangularGradient
}
/// <summary>
/// Colour index.
/// <para>Ref. Microsoft.Office.Interop.Excel.XlColorIndex.</para>
/// </summary>
public enum SaXlColourIndex
{
NotSpecified = int.MinValue,
/// <summary>No color. -4142, &HFFFFEFD2.</summary>
None = XlColorIndex.xlColorIndexNone,
/// <summary>Automatic color. -4105, &HFFFFEFF7.</summary>
Automatic = XlColorIndex.xlColorIndexAutomatic,
Black = 1,
White = 2,
Red = 3,
BrightGreen = 4,
Blue = 5,
Yellow = 6,
Pink = 7,
Magenta = 7,
Turqoise = 8,
Cyan = 8,
DarkRed = 9,
Green = 10,
DarkBlue = 11,
DarkYellow = 12,
Violet = 13,
Teal = 14,
Gray25 = 15,
Gray50 = 16,
SkyBlue = 33,
LightTurqoise = 34,
LightGreen = 35,
LightYellow = 36,
PaleBlue = 37,
Rose = 38,
Lavendar = 39,
Tan = 40,
LightBlue = 41,
Aqua = 42,
Lime = 43,
Gold = 44,
LightOrange = 45,
Orange = 46,
BlueGray = 47,
Gray40 = 48,
DarkTeal = 49,
SeaGreen = 50,
DarkGreen = 51,
OliveGreen = 52,
Brown = 53,
Plum = 54,
Indigo = 55,
Gray80 = 56,
};
/// <summary>
/// RGB colour value.
/// <para>Ref. Microsoft.Office.Interop.Excel.XlRgbColor.</para>
/// </summary>
public enum SaXlRgbColor
{
NotSpecified = int.MinValue,
Red = XlRgbColor.rgbRed,
}
/// <summary>
/// Specifies the type of underline applied to a font.
/// <para>Ref. Microsoft.Office.Interop.Excel.XlUnderlineStyle</para>
/// </summary>
public enum SaXlUnderlineStyle
{
/// <summary>No underlining.</summary>
None = XlUnderlineStyle.xlUnderlineStyleNone,
/// <summary>Double thick underline.</summary>
Double = XlUnderlineStyle.xlUnderlineStyleDouble,
/// <summary>Single underlining.</summary>
Single = XlUnderlineStyle.xlUnderlineStyleSingle,
/// <summary>Single accounting - Not supported.</summary>
SingleAccounting = XlUnderlineStyle.xlUnderlineStyleSingleAccounting,
/// <summary>Double accounting - Two thin underlines placed close together.</summary>
DoubleAccounting = XlUnderlineStyle.xlUnderlineStyleDoubleAccounting
}
//=======================================================================
}