RunPython.h 993 B

123456789101112131415161718192021222324252627282930
  1. // 下列 ifdef 块是创建使从 DLL 导出更简单的
  2. // 宏的标准方法。此 DLL 中的所有文件都是用命令行上定义的 RUNPYTHON_EXPORTS
  3. // 符号编译的。在使用此 DLL 的
  4. // 任何其他项目上不应定义此符号。这样,源文件中包含此文件的任何其他项目都会将
  5. // RUNPYTHON_API 函数视为是从 DLL 导入的,而此 DLL 则将用此宏定义的
  6. // 符号视为是被导出的。
  7. #ifdef RUNPYTHON_EXPORTS
  8. #define RUNPYTHON_API __declspec(dllexport)
  9. #else
  10. #define RUNPYTHON_API __declspec(dllimport)
  11. #endif
  12. // 此类是从 RunPython.dll 导出的
  13. //class RUNPYTHON_API CRunPython {
  14. //public:
  15. // CRunPython(void);
  16. // // TODO: 在此添加您的方法。
  17. //};
  18. //
  19. //extern RUNPYTHON_API int nRunPython;
  20. // 运行脚本;
  21. RUNPYTHON_API DWORD RunPyScript(LPCTSTR lpScriptFile, LPCTSTR lpExtraSentence, LPCTSTR lpScriptLog, BOOL bSubProcess);
  22. // 结束脚本;
  23. RUNPYTHON_API bool StopPyScript(DWORD dwScriptId, BOOL bSubProcess);
  24. // 脚本是否结束;
  25. RUNPYTHON_API bool IsPyScriptOver(DWORD dwScriptId, BOOL bSubProcess);
  26. // 清除脚本;
  27. RUNPYTHON_API void CleanPyScript(DWORD dwScriptId);