I
iamfly
Unregistered / Unconfirmed
GUEST, unregistred user!
var<br> lppe: TProcessEntry32;<br> found: boolean;<br> Hand: THandle;<br> err:integer;<br>begin<br> Listproc1.Items.Clear;<br> Hand:=CreateToolhelp32Snapshot(TH32CS_SNAPALL,0);<br> found:=Process32First(Hand,lppe);//错误就在这里出现,found值不为TRUE<br> err:=getlasterror();<br><br>ERR的值为24,在DELPHI的WIN32帮助中找到24的错误描述为<br>ERROR_BAD_LENGTH<br>The program issued a command but the command length is incorrect.<br>再运行一次,ERR值变成120,即是<br>ERROR_CALL_NOT_IMPLEMENTED<br>The Application Program Interface (API) entered will only work in Windows/NT mode.