/*------------------------------------------------------------------------------*
 * File Name:ANOVAOneWay.h														*
 * Creation:  GRD 2002.08.09													*
 * Purpose: OriginC header file for declaration of  One Way ANOVA operation 	*
 * Copyright (c) ABCD Corp.	2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010		*
 * All Rights Reserved															*
 * 																				*
 * Modification Log:															*
 *	Cheney 2006-6-26 REWRITE													*
 *	Hong 07/17/08 v8.0903 FIX_SOME_IMPORT_HAVE_DUPLICATE_SHEET_NAME_NO_AUTO_ENUM*
 *------------------------------------------------------------------------------*/
 
 #ifndef _KGRAPH_H
 #define _KGRAPH_H
 
 //Error Message
enum{
	KG_ERR_FAIL_TO_OPEN_FILE				=	-10,			
	KG_ERR_FILE_TOO_SMALL,			
	KG_ERR_NUMBER_OF_COLUMNS_INCONSISTENT,			
	KG_ERR_UNSUPPORTED_DATA_TYPE,			
	KG_ERR_UNSUPPORTED_VERSION,
	KG_ERR_FAIL_TO_READ_FILE_INFO,
	KG_ERR_FAIL_TO_READ_DATA
};

/// Hong 07/17/08 v8.0903 FIX_SOME_IMPORT_HAVE_DUPLICATE_SHEET_NAME_NO_AUTO_ENUM
enum
{
	KGRAPH_RENAME_SHEET_BY_FILENAME			= 0x00000001,
};
/// end FIX_SOME_IMPORT_HAVE_DUPLICATE_SHEET_NAME_NO_AUTO_ENUM

// read kaleidgraph file
// return number of column of importing data, or negtive for error.
/// Hong 07/17/08 v8.0903 FIX_SOME_IMPORT_HAVE_DUPLICATE_SHEET_NAME_NO_AUTO_ENUM
//int readkgraph(LPCSTR lpcszFilename, Worksheet& wks, TreeNode& trInfo, int nC1 = 0);
int readkgraph(LPCSTR lpcszFilename, Worksheet& wks, TreeNode& trInfo, int nC1 = 0, DWORD dwOptions = KGRAPH_RENAME_SHEET_BY_FILENAME);
/// end FIX_SOME_IMPORT_HAVE_DUPLICATE_SHEET_NAME_NO_AUTO_ENUM

#endif // _KGRAPH_H
