天软金融分析.NET函数大全 > TSL函数 > 第三方交互函数 > 外部交互扩展调用接口 > DLL外部函数引入

32位windows下的调用方式申明    

  • 一般的调用方式的申明约定有以下这几种:
    Register
    Pascal
    Cdecl
    Stdcall
    Safecall
    Fastcall
    Windows的API使用stdcall模式。
    默认情况下,我们采用cdecl申明模式:
    Function TS_strtofloat(s:string):double;external "tslkrnl.dll" name "TS_strtofloat";
    等同于:
    Function TS_strtofloat(s:string):double;cdecl;external "tslkrnl.dll" name "TS_strtofloat";
    除了Win32以外,每种CPU架构下只有一套标准调用模式,不需考虑是stdcall还是cdecl。目前只有Win32还需要考虑调用方式的申明。