易截截图软件、单文件、免安装、纯绿色、仅160KB

Excel writing and reading with pure c API

Reading and Writing Excel file with pure C api in windows system. tested on windows 2000, hope it can help you:
#ifndef _WINXLS_H_
#define _WINXLS_H_
/*============================================================================*
*      Include Files
*============================================================================*/
#include <windows.h>
#include <Oleauto.h>    /* SysAllocString */
#include <objbase.h>    /* CoCreateInstance, ... */
#pragma comment(lib, "ole32.lib")
#include "mytypes.h"    /* tInt32, ...        */
#include "mydll.h"    /* define EXPORT     */
/*============================================================================*
*    define/typedef/struct
*============================================================================*/
#define DISP_CELL    170
/* XLS file handle */
typedef struct
{
    tChar*        filepath;
    IDispatch*    bookhandle;
    IDispatch*    sheetshandle;
    IDispatch**    sheethandles;    // Array of IDispatch*
    IDispatch**    rangehandles;    // Array of IDispatch*
    tUInt32        sheet_count;
}XLSFILE;
/*============================================================================*
*    Const variables
*============================================================================*/
/*============================================================================*
*    Global variables
*============================================================================*/
/*==============================================


相关文档:

C和指针学习笔记(1)

       1、 经常看见return EXIT_SUCCESS或return EXIT_FAILURE,但都不知这两个来自何处,现在才知原来stdlib.h定义了EXIT_SUCCESS和EXIT_FAILURE符号。
在stdlib.h头文件里:
#define EXIT_SUCCESS    0
#define EXIT_FAILURE    1
    & ......

C练习题

1.  给定等式  A B C D E     其中每个字母代表一个数字,且不同数字对应不
                    D F G    &nbs ......

关于C中结构体的大小问题(sizeof)

作者:
曾宏安,华清远见嵌入式学院
高级讲师。
运算符sizeof可以计算出给定类型的大小,对于32位系统来说,sizeof(char) = 1; sizeof(int) = 4。基本数据类型的大小很好计算,我们来看一下如何计算构造数据类型的大小。
C语言中的构造数据类型有三种:数组、结构体和共用体。
数组是相同类型的元素的集合,只要会计算 ......

Pipe is a worm hole connecting C and C++

In C programming language, the observer design pattern is implemented with function pointer (aka callback function). But in Qt library, it introduces signal and slot. How to link a callback function from the C callback function to the C++ siganl and slot is a problem I encounter. Call back function ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号