I have a function from the Jedi JCL RunningProcessList that is defined as follows....

procedure RunningProcessesList(AList: TStrings; ABoolean: Boolean)

The documentation states that the function places the running binary name in the AList.Strings[n] index and the process id in the AList.Objects[n] as a pointed to an integer.

How do I de-reference this to get the actual value. In the function it is assigning the values as follows.

List.AddObject(FileName, Pointer(ProcEntry.th32ProcessID));

where ProcEntry: TProcessEntry32;

How do I get the PID assigned to the Objects field?

有帮助吗?

解决方案

The PID is

PID := DWORD(List.Objects[Index]);

Where Index is the index of the item of interest.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top