亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來(lái)到蟲(chóng)蟲(chóng)下載站! | ?? 資源下載 ?? 資源專(zhuān)輯 ?? 關(guān)于我們
? 蟲(chóng)蟲(chóng)下載站

?? basicexcelvc6.hpp

?? 對(duì)EXCEL的操作
?? HPP
?? 第 1 頁(yè) / 共 3 頁(yè)
字號(hào):
				struct BoolErr : public Record
				{
					BoolErr();
					virtual size_t Read(const char* data);
					virtual size_t Write(char* data);	
					short rowIndex_;
					short colIndex_;
					short XFRecordIndex_;
					char value_;
					char error_;	
				};
				struct LabelSST : public Record
				{
					LabelSST();
					virtual size_t Read(const char* data);
					virtual size_t Write(char* data);	
					short rowIndex_;
					short colIndex_;
					short XFRecordIndex_;
					size_t SSTRecordIndex_;	
				};
				struct MulBlank : public Record
				{
					MulBlank();
					virtual size_t Read(const char* data);
					virtual size_t Write(char* data);	
					virtual size_t DataSize();
					virtual size_t RecordSize();
					short rowIndex_;
					short firstColIndex_;
					vector<short> XFRecordIndices_;
					short lastColIndex_;
				};
				struct MulRK : public Record
				{
					MulRK();
					virtual size_t Read(const char* data);
					virtual size_t Write(char* data);
					virtual size_t DataSize();
					virtual size_t RecordSize();
					struct XFRK
					{
						XFRK();
						void Read(const char* data);
						void Write(char* data);
						short XFRecordIndex_;
						int RKValue_;
					};
					short rowIndex_;
					short firstColIndex_;
					vector<XFRK> XFRK_;
					short lastColIndex_;
				};
				struct Number : public Record
				{
					Number();
					virtual size_t Read(const char* data);
					virtual size_t Write(char* data);	
					short rowIndex_;
					short colIndex_;
					short XFRecordIndex_;
					double value_;

				private:
					union 
					{
						__int64 intvalue_;
						double doublevalue_;
					} intdouble_;
				};
				struct RK : public Record
				{
					RK();
					virtual size_t Read(const char* data);
					virtual size_t Write(char* data);	
					short rowIndex_;
					short colIndex_;
					short XFRecordIndex_;
					int value_;	
				};

				struct Formula : public Record
				{
					struct Array : public Record
					{
						Array();
						virtual size_t Read(const char* data);
						virtual size_t Write(char* data);	
						virtual size_t DataSize();
						virtual size_t RecordSize();
						short firstRowIndex_;
						short lastRowIndex_;
						char firstColIndex_;
						char lastColIndex_;
						short options_;
						int unused_;
						vector<char> formula_;
					};
					struct ShrFmla : public Record
					{
						ShrFmla();
						virtual size_t Read(const char* data);
						virtual size_t Write(char* data);	
						virtual size_t DataSize();
						virtual size_t RecordSize();
						short firstRowIndex_;
						short lastRowIndex_;
						char firstColIndex_;
						char lastColIndex_;
						short unused_;
						vector<char> formula_;
					};
					struct ShrFmla1 : public Record
					{
						ShrFmla1();
						virtual size_t Read(const char* data);
						virtual size_t Write(char* data);	
						virtual size_t DataSize();
						virtual size_t RecordSize();
						short firstRowIndex_;
						short lastRowIndex_;
						char firstColIndex_;
						char lastColIndex_;
						short unused_;
						vector<char> formula_;
					};
					struct Table : public Record
					{
						Table();
						virtual size_t Read(const char* data);
						virtual size_t Write(char* data);	
						short firstRowIndex_;
						short lastRowIndex_;
						char firstColIndex_;
						char lastColIndex_;
						short options_;
						short inputCellRowIndex_;
						short inputCellColIndex_;
						short inputCellColumnInputRowIndex_;
						short inputCellColumnInputColIndex_;
					};
					struct String : public Record
					{
						String();
						virtual size_t Read(const char* data);
						virtual size_t Write(char* data);	
						virtual size_t DataSize();
						virtual size_t RecordSize();
						vector<wchar_t> string_;
					};

					Formula();
					virtual size_t Read(const char* data);
					virtual size_t Write(char* data);	
					virtual size_t DataSize();
					virtual size_t RecordSize();
					short rowIndex_;
					short colIndex_;
					short XFRecordIndex_;
					char result_[8];
					short options_;
					int unused_;
					vector<char> RPNtoken_;
					short type_;

					Array array_;
					ShrFmla shrfmla_;
					ShrFmla1 shrfmla1_;
					Table table_;
					String string_;
				};

				CellBlock();
				~CellBlock();
				void Reset();
				size_t Read(const char* data);
				size_t Write(char* data);
				size_t DataSize();
				size_t RecordSize();
				short RowIndex();
				short ColIndex();
				short LastColIndex();
				short type_;
				bool normalType_;
				
				Blank blank_;
				BoolErr boolerr_;
				LabelSST labelsst_;
				MulBlank mulblank_;
				MulRK mulrk_;
				Number number_;
				RK rk_;
				Formula formula_;
			};
			struct DBCell : public Record
			{
				DBCell();
				virtual size_t Read(const char* data);
				virtual size_t Write(char* data);	
				virtual size_t DataSize();
				virtual size_t RecordSize();
				int firstRowOffset_;
				vector<short> offsets_;
			};			
			
			size_t Read(const char* data);
			size_t Write(char* data);
			size_t DataSize();
			size_t RecordSize();
		
			vector<Row> rows_;
			vector<CellBlock> cellBlocks_;
			DBCell dbcell_;
		};	
		size_t Read(const char* data);
		size_t Write(char* data);
		size_t DataSize();
		size_t RecordSize();
	
		vector<RowBlock> rowBlocks_;		
	};
	struct Window2 : public Record
	{
		Window2();
		virtual size_t Read(const char* data);
		virtual size_t Write(char* data);	
		short options_;
		short firstVisibleRowIndex_;
		short firstVisibleColIndex_;
		short gridLineColourIndex_;
		short unused1_;
		short magnificationFactorPageBreakPreview_;
		short magnificationFactorNormalView_;
		int unused2_;		
	};
	struct SCL;
	struct Pane;
	struct Selection;
	struct MergedCells;
	struct LabelRanges;
	struct ConditionalFormattingTable;
	struct HyperlinkTable;
	struct SheetLayout;
	struct SheetProtection;
	struct RangeProtection;

	size_t Read(const char* data);
	size_t Write(char* data);
	size_t DataSize();
	size_t RecordSize();

	BOF bof_;
	Index index_;
	Dimensions dimensions_;
	CellTable cellTable_;
	Window2 window2_;
	YEOF eof_;
};

bool IsRKValueAnInteger(int rkValue);		///< Returns true if the supplied rk value contains an integer. 
bool IsRKValueADouble(int rkValue);			///< Returns true if the supplied rk value contains a double.
double GetDoubleFromRKValue(int rkValue);	///< Convert a rk value to a double.
int GetIntegerFromRKValue(int rkValue);		///< Convert a rk value to an integer.
int GetRKValueFromDouble(double value);		///< Convert a double to a rk value.
int GetRKValueFromInteger(int value);		///< Convert an integer to a rk value.
bool CanStoreAsRKValue(double value);		///< Returns true if the supplied double can be stored as a rk value.

// Forward declarations
class BasicExcel;
class BasicExcelWorksheet;
class BasicExcelCell;

/*******************************************************************************************************/
/*                         Actual classes to read and write to Excel files                             */
/*******************************************************************************************************/
class BasicExcel
{
public:
	BasicExcel();
	BasicExcel(const char* filename);
	~BasicExcel();

public: // File functions.
	void New(int sheets=3);	///< Create a new Excel workbook with a given number of spreadsheets (Minimum 1).
	bool Load(const char* filename);	///< Load an Excel workbook from a file.
	bool Save();	///< Save current Excel workbook to opened file.
	bool SaveAs(const char* filename);	///< Save current Excel workbook to a file.

public: // Worksheet functions.
	size_t GetTotalWorkSheets();	///< Total number of Excel worksheets in current Excel workbook.

	BasicExcelWorksheet* GetWorksheet(size_t sheetIndex);	///< Get a pointer to an Excel worksheet at the given index. Index starts from 0. Returns 0 if index is invalid.
	BasicExcelWorksheet* GetWorksheet(const char* name);	///< Get a pointer to an Excel worksheet that has given ANSI name. Returns 0 if there is no Excel worksheet with the given name.
	BasicExcelWorksheet* GetWorksheet(const wchar_t* name);	///< Get a pointer to an Excel worksheet that has given Unicode name. Returns 0 if there is no Excel worksheet with the given name.
	
	BasicExcelWorksheet* AddWorksheet(int sheetIndex=-1);	///< Add a new Excel worksheet to the given index. Name given to worksheet is SheetX, where X is a number which starts from 1. Index starts from 0. Worksheet is added to the last position if sheetIndex == -1. Returns a pointer to the worksheet if successful, 0 if otherwise.
	BasicExcelWorksheet* AddWorksheet(const char* name, int sheetIndex=-1);	///< Add a new Excel worksheet with given ANSI name to the given index. Index starts from 0. Worksheet is added to the last position if sheetIndex == -1. Returns a pointer to the worksheet if successful, 0 if otherwise.
	BasicExcelWorksheet* AddWorksheet(const wchar_t* name, int sheetIndex=-1);	///< Add a new Excel worksheet with given Unicode name to the given index. Index starts from 0. Worksheet is added to the last position if sheetIndex == -1. Returns a pointer to the worksheet if successful, 0 if otherwise.

	bool DeleteWorksheet(size_t sheetIndex);	///< Delete an Excel worksheet at the given index. Index starts from 0. Returns true if successful, false if otherwise.
	bool DeleteWorksheet(const char* name);		///< Delete an Excel worksheet that has given ANSI name. Returns true if successful, false if otherwise.
	bool DeleteWorksheet(const wchar_t* name);	///< Delete an Excel worksheet that has given Unicode name. Returns true if successful, false if otherwise.

	char* GetAnsiSheetName(size_t sheetIndex);	///< Get the worksheet name at the given index. Index starts from 0. Returns 0 if name is in Unicode format.
	wchar_t* GetUnicodeSheetName(size_t sheetIndex);///< Get the worksheet name at the given index. Index starts from 0. Returns 0 if name is in Ansi format.
	bool GetSheetName(size_t sheetIndex, char* name);		///< Get the worksheet name at the given index. Index starts from 0. Returns false if name is in Unicode format.
	bool GetSheetName(size_t sheetIndex, wchar_t* name);	///< Get the worksheet name at the given index. Index starts from 0. Returns false if name is in Ansi format.

	bool RenameWorksheet(size_t sheetIndex, const char* to);		///< Rename an Excel worksheet at the given index to the given ANSI name. Index starts from 0. Returns true if successful, false if otherwise.
	bool RenameWorksheet(size_t sheetIndex, const wchar_t* to);		///< Rename an Excel worksheet at the given index to the given Unicode name. Index starts from 0. Returns true if successful, false if otherwise.
	bool RenameWorksheet(const char* from, const char* to);			///< Rename an Excel worksheet that has given ANSI name to another ANSI name. Returns true if successful, false if otherwise.
	bool RenameWorksheet(const wchar_t* from, const wchar_t* to);	///< Rename an Excel worksheet that has given Unicode name to another Unicode name. Returns true if successful, false if otherwise.

private: // Functions to read and write raw Excel format.
	size_t Read(const char* data, size_t dataSize);
	size_t Write(char* data);
	void AdjustStreamPositions();
	void AdjustBoundSheetBOFPositions();
	void AdjustDBCellPositions();
	void AdjustExtSSTPositions();

	enum {WORKBOOK_GLOBALS=0x0005, VISUAL_BASIC_MODULE=0x0006,
		  WORKSHEET=0x0010, CHART=0x0020};
	
private: // Internal functions
	void UpdateYExcelWorksheet();	///< Update yesheets_ using information from worksheets_.
	void UpdateWorksheets();		///< Update worksheets_ using information from yesheets_.

public:
	CompoundFile file_;						///< Compound file handler.
	Workbook workbook_;						///< Raw Workbook.
	vector<Worksheet> worksheets_;			///< Raw Worksheets.
	vector<BasicExcelWorksheet> yesheets_;	///< Parsed Worksheets.
};

class BasicExcelWorksheet
{
	friend class BasicExcel;

public:
	BasicExcelWorksheet(BasicExcel* excel, size_t sheetIndex);

public: // Worksheet functions
	char* GetAnsiSheetName();	///< Get the current worksheet name. Returns 0 if name is in Unicode format.
	wchar_t* GetUnicodeSheetName();///< Get the current worksheet name. Returns 0 if name is in Ansi format.
	bool GetSheetName(char* name);		///< Get the current worksheet name. Returns false if name is in Unicode format.
	bool GetSheetName(wchar_t* name);	///< Get the current worksheet name. Returns false if name is in Ansi format.
	bool Rename(const char* to);	///< Rename current Excel worksheet to another ANSI name. Returns true if successful, false if otherwise.
	bool Rename(const wchar_t* to);///< Rename current Excel worksheet to another Unicode name. Returns true if successful, false if otherwise.
	void Print(ostream& os, char delimiter=',', char textQualifier='\0'); ///< Print entire worksheet to an output stream, separating each column with the defined delimiter and enclosing text using the defined textQualifier. Leave out the textQualifier argument if do not wish to have any text qualifiers.

public: // Cell functions
	size_t GetTotalRows();	///< Total number of rows in current Excel worksheet.
	size_t GetTotalCols();	///< Total number of columns in current Excel worksheet.

	BasicExcelCell* Cell(size_t row, size_t col); ///< Return a pointer to an Excel cell. row and col starts from 0. Returns 0 if row exceeds 65535 or col exceeds 255.
	bool EraseCell(size_t row, size_t col); ///< Erase content of a cell. row and col starts from 0. Returns true if successful, false if row or col exceeds range.

private: // Internal functions
	void UpdateCells();	///< Update cells using information from BasicExcel.worksheets_.

private:
	BasicExcel* excel_;					///< Pointer to instance of BasicExcel.
	size_t sheetIndex_;					///< Index of worksheet in workbook.
	size_t maxRows_;					///< Total number of rows in worksheet.
	size_t maxCols_;					///< Total number of columns in worksheet.
	vector<vector<BasicExcelCell> > cells_;	///< Cells matrix.
};

class BasicExcelCell
{
public:
	BasicExcelCell();

public:
	enum {UNDEFINED, INT, DOUBLE, STRING, WSTRING};
	int Type() const;		///< Get type of value stored in current Excel cell. Returns one of the above enums. 

	bool Get(int& val) const;		///< Get an integer value. Returns false if cell does not contain an integer.
	bool Get(double& val) const;	///< Get a double value. Returns false if cell does not contain a double.
	bool Get(char* str) const;	///< Get an ANSI string. Returns false if cell does not contain an ANSI string.
	bool Get(wchar_t* str) const;	///< Get an Unicode string. Returns false if cell does not contain an Unicode string.
	size_t GetStringLength() const;	///< Return length of ANSI or Unicode string (excluding null character).

	int GetInteger() const;		///< Get an integer value. Returns 0 if cell does not contain an integer.
	double GetDouble() const;		///< Get a double value. Returns 0.0 if cell does not contain a double.
	const char* GetString() const;		///< Get an ANSI string. Returns 0 if cell does not contain an ANSI string.
	const wchar_t* GetWString() const;	///< Get an Unicode string. Returns 0 if cell does not contain an Unicode string.

	friend ostream& operator<<(ostream& os, const BasicExcelCell& cell);	///< Print cell to output stream. Print a null character if cell is undefined.

	void Set(int val);				///< Set content of current Excel cell to an integer.
	void Set(double val);			///< Set content of current Excel cell to a double.
	void Set(const char* str);		///< Set content of current Excel cell to an ANSI string.
	void Set(const wchar_t* str);	///< Set content of current Excel cell to an Unicode string.
	
	void SetInteger(int val);			///< Set content of current Excel cell to an integer.
	void SetDouble(double val);			///< Set content of current Excel cell to a double.
	void SetString(const char* str);	///< Set content of current Excel cell to an ANSI string.
	void SetWString(const wchar_t* str);///< Set content of current Excel cell to an Unicode string.

	void EraseContents();	///< Erase the content of current Excel cell. Set type to UNDEFINED.

private:
	int type_;				///< Type of value stored in current Excel cell. Contains one of the above enums.
	int ival_;				///< Integer value stored in current Excel cell.
	double dval_;			///< Double value stored in current Excel cell.
	vector<char> str_;		///< ANSI string stored in current Excel cell. Include null character.
	vector<wchar_t> wstr_;	///< Unicode string stored in current Excel cell. Include null character.
};

} // Namespace end
#endif

?? 快捷鍵說(shuō)明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲国产精品一区二区久久| 26uuu精品一区二区三区四区在线| 蜜臀av国产精品久久久久| 一区二区三区四区在线播放| 国产精品免费视频网站| 国产精品美女一区二区三区| 国产精品第四页| 亚洲精品欧美激情| 亚洲二区在线视频| 婷婷夜色潮精品综合在线| 青青草伊人久久| 麻豆高清免费国产一区| 国产九九视频一区二区三区| 成人综合日日夜夜| 99精品热视频| 欧美三级一区二区| 日韩无一区二区| 国产女人水真多18毛片18精品视频| 中文字幕av资源一区| 亚洲午夜在线观看视频在线| 日本亚洲视频在线| 国产不卡在线一区| 在线日韩国产精品| 日韩视频在线一区二区| 国产精品激情偷乱一区二区∴| 亚洲精品国产成人久久av盗摄| 亚洲综合激情网| 精品夜夜嗨av一区二区三区| 成人黄色电影在线 | 自拍av一区二区三区| 亚洲日本丝袜连裤袜办公室| 人人精品人人爱| 91同城在线观看| 精品福利一二区| 尤物视频一区二区| 极品销魂美女一区二区三区| 色综合视频一区二区三区高清| 欧美一级理论片| 亚洲人成网站精品片在线观看 | 精品国产成人在线影院| 中文字幕一区二区三区在线播放 | 亚洲成人在线免费| 国产老妇另类xxxxx| 一本色道久久综合亚洲精品按摩| 日韩一区二区高清| 亚洲国产wwwccc36天堂| 成人国产电影网| 精品久久久久99| 天堂蜜桃91精品| 日本视频一区二区| 在线免费亚洲电影| 国产精品丝袜在线| 国产成人a级片| 日韩欧美国产麻豆| 日韩不卡免费视频| 欧美综合一区二区三区| 欧美激情在线看| 精品亚洲aⅴ乱码一区二区三区| 欧美日韩在线播放三区四区| 国产精品区一区二区三| 国产一区视频导航| 日韩免费看的电影| 蜜臀av性久久久久蜜臀aⅴ四虎| 91黄色免费网站| 中文字幕在线一区免费| 粉嫩蜜臀av国产精品网站| 26uuu欧美日本| 久久99国产精品久久99| 精品国产一区二区国模嫣然| 久久精品国产999大香线蕉| 欧美裸体一区二区三区| 亚洲国产乱码最新视频| 欧美在线观看禁18| 午夜视频在线观看一区二区 | 91麻豆国产在线观看| 国产欧美日本一区视频| 国产成人aaa| 亚洲国产高清在线| 成人av电影观看| 亚洲精品欧美专区| 欧美怡红院视频| 日韩高清在线不卡| 日韩欧美国产不卡| 国产成人免费视频一区| 亚洲国产成人在线| 91在线你懂得| 日日夜夜精品视频免费| 日韩精品自拍偷拍| 国产盗摄精品一区二区三区在线 | 三级影片在线观看欧美日韩一区二区| 在线免费不卡电影| 日韩精品色哟哟| 久久精品视频免费| 成人黄色在线视频| 婷婷一区二区三区| 2023国产一二三区日本精品2022| 国产宾馆实践打屁股91| 一区二区三区四区高清精品免费观看| 欧美午夜寂寞影院| 久热成人在线视频| 中文字幕在线观看不卡视频| 欧美视频一区在线观看| 黄色成人免费在线| 亚洲日本欧美天堂| 日韩无一区二区| 色先锋资源久久综合| 久久国产精品99久久久久久老狼 | 国产成人小视频| 国产很黄免费观看久久| 成+人+亚洲+综合天堂| 亚洲一二三区不卡| 精品av久久707| 欧美在线免费视屏| 国产一区二区不卡| 婷婷久久综合九色国产成人 | 国产盗摄一区二区三区| 亚洲成人午夜影院| 欧美国产综合一区二区| 9191成人精品久久| 91影院在线观看| 久久草av在线| 一区二区欧美精品| 国产精品高潮呻吟| 精品久久久久久久久久久久包黑料 | 国产精品美女久久久久久久久久久 | 欧美v日韩v国产v| 91影视在线播放| 国产999精品久久久久久| 天堂一区二区在线| 亚洲日本一区二区| 欧美国产乱子伦| 精品久久久久久久久久久院品网 | 91久久精品日日躁夜夜躁欧美| 免费三级欧美电影| 五月天一区二区三区| 综合激情成人伊人| 中文字幕av一区 二区| 久久伊人中文字幕| 欧美变态凌虐bdsm| 日韩亚洲欧美高清| 91精品在线观看入口| 欧美三级乱人伦电影| 91国产福利在线| 一本一本久久a久久精品综合麻豆| 国产呦萝稀缺另类资源| 亚洲国产精品天堂| 国产精品福利一区二区三区| 精品国产伦一区二区三区观看体验| 欧美日韩精品一二三区| 欧美日本一区二区| 欧美高清视频一二三区| 欧美情侣在线播放| 欧美一级二级三级乱码| 91精品欧美综合在线观看最新| 91国偷自产一区二区三区观看| 色综合色综合色综合| 欧美专区亚洲专区| 欧美日韩一区二区三区视频| 欧美精品高清视频| 日韩欧美亚洲国产精品字幕久久久| 日韩一区二区在线播放| 欧美电影免费观看高清完整版| 欧美一区二区三区在线看| 欧美一区二区人人喊爽| 日韩免费一区二区| 中文无字幕一区二区三区| 国产精品久久久99| 亚洲精品乱码久久久久久久久 | 亚洲女同ⅹxx女同tv| 国产精品久久久久久福利一牛影视 | 五月天久久比比资源色| 亚洲丶国产丶欧美一区二区三区| 日本免费新一区视频| 激情六月婷婷久久| 91亚洲国产成人精品一区二三| 99精品久久只有精品| 色婷婷亚洲综合| 日韩一区二区电影| 国产精品少妇自拍| 亚洲chinese男男1069| 国内外成人在线| 94色蜜桃网一区二区三区| 91精品啪在线观看国产60岁| 国产精品婷婷午夜在线观看| 亚洲综合免费观看高清在线观看| 蜜臀a∨国产成人精品| 97精品国产露脸对白| 91精品国产综合久久久蜜臀图片| 久久精品夜色噜噜亚洲aⅴ| 亚洲一区在线看| 国产 日韩 欧美大片| 91精选在线观看| 亚洲女同一区二区| 国产精品一色哟哟哟| 欧美日韩国产精品成人| 国产精品久久夜| 久久99精品久久久久久动态图| 99久久夜色精品国产网站| 日韩视频一区在线观看| 亚洲一区二区四区蜜桃|