nineteenfourrecord.cs

来自「Excel的操作,其中可以读取及写入Excel 文件」· CS 代码 · 共 40 行

CS
40
字号
using System;

using Microsoft.Fawvw.Components.NExcel.Biff;

namespace Microsoft.Fawvw.Components.NExcel.Read.Biff
{
	
	/// <summary> Identifies the date system as the 1904 system or not</summary>
	class NineteenFourRecord:RecordData
	{
		/// <summary> The base year for dates</summary>
		private bool nineteenFour;
		
		/// <summary> Constructs this object from the raw data
		/// 
		/// </summary>
		/// <param name="t">the raw data
		/// </param>
		public NineteenFourRecord(Record t):base(t)
		{
			
			sbyte[] data = getRecord().Data;
			
			nineteenFour = data[0] == 1?true:false;
		}
		
		/// <summary> Accessor to see whether this spreadsheets dates are based around
		/// 1904
		/// 
		/// </summary>
		/// <returns> true if this workbooks dates are based around the 1904
		/// date system
		/// </returns>
		public virtual bool is1904()
		{
			return nineteenFour;
		}
	}
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?