|
部分代码:
procedure TFileWatchThread.Execute;
var
numBytes: DWORD;
CompletionKey: DWORD;
begin
while not Terminated do
begin
GetQueuedCompletionStatus( FPCompletionPort^, numBytes, CompletionKey, FPOverlapped, INFINITE);
if CompletionKey <> 0 then
begin
Synchronize(HandleEvent);
FBytesWritten := 0;
ZeroMemory(@FNotificationBuffer, SizeOf(FNotificationBuffer));
ReadDirectoryChanges(FPDirectoryHandle^, @FNotificationBuffer,
SizeOf(FNotificationBuffer), WatchSubTree, FNotifyFilter,
@FBytesWritten, @FOverlapped, nil);
end
else
Terminate;
end;
end;
完整代码见附件,代码部分有点儿长,就没有全部贴出来。
~~~~~~~~~~
出错提示: [dcc32 Error] Unit1.pas(185): E2033 Types of actual and formal var parameters must be identical
用D7可直接编译没有问题,换成delphi 10.2.3编译就不行了。求大神带路。~
出错点就在 GetQueuedCompletionStatus( FPCompletionPort^, numBytes, CompletionKey, FPOverlapped, INFINITE); 这一句。。
|
本帖子中包含更多资源
您需要 登录 才可以下载或查看,没有帐号?立即注册
x
|