TAPI、lineInitialize 和 lineInitializeEx
我尝试在我的 Delphi 项目中使用 TAPI。
当我使用 lineInitializeEx 而不是 lineInitialize 时,我收到一条错误消息,例如“异常处理消息 c0000139 参数 168fc8 162820 75b4bf7c 75b4bf7c”
lineInitializeEx 的代码是:
var
initPrm: TLineInitializeExParams;
begin
FillChar(initPrm, SizeOf(initPrm), 0);
initPrm.dwTotalSize := SizeOf(initPrm);
initPrm.dwOptions := LINEINITIALIZEEXOPTION_USEEVENT; // or LINEINITIALIZEEXOPTION_USEHIDDENWINDOW
if lineInitializeEx(lineApp, HInstance, lineCallback, 'TAPI sample', nDevs, tapiVersion, initPrm) < 0 then
TLineInitializeExParams 的定义是:
TLineInitializeExParams = record
dwTotalSize,
dwNeededSize,
dwUsedSize,
dwOptions: Longint;
Handles: THandleUnion;
dwCompletionKey: Longint;
end;
当我使用 lineInitialize 时,
if lineInitialize(lineApp, HInstance, lineCallback, 'TAPI sample', nDevs) < 0 then
一切正常。
有什么想法吗?
I try to use TAPI in my Delphi project.
When I use lineInitializeEx instead of lineInitialize I get an error msg like "Exception Processing Message c0000139 Parameters 168fc8 162820 75b4bf7c 75b4bf7c"
The code with lineInitializeEx is :
var
initPrm: TLineInitializeExParams;
begin
FillChar(initPrm, SizeOf(initPrm), 0);
initPrm.dwTotalSize := SizeOf(initPrm);
initPrm.dwOptions := LINEINITIALIZEEXOPTION_USEEVENT; // or LINEINITIALIZEEXOPTION_USEHIDDENWINDOW
if lineInitializeEx(lineApp, HInstance, lineCallback, 'TAPI sample', nDevs, tapiVersion, initPrm) < 0 then
and definition of TLineInitializeExParams is:
TLineInitializeExParams = record
dwTotalSize,
dwNeededSize,
dwUsedSize,
dwOptions: Longint;
Handles: THandleUnion;
dwCompletionKey: Longint;
end;
When I use lineInitialize
if lineInitialize(lineApp, HInstance, lineCallback, 'TAPI sample', nDevs) < 0 then
everything is OK.
Is there any idea ?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
TurboPower Async Professional 可能值得一看,它现已开源。这就是我们用来成功实施 TAPI 项目的方法。
https://sourceforge.net/projects/tpapro/
Might be worth looking at TurboPower Async Professional, which is now open source. This is what we used to successfully implement a TAPI project.
https://sourceforge.net/projects/tpapro/