Question about definition of PROCESSENTRY32 structure
Posted: Wed Jan 23, 2008 1:14 am
The PROCESSENTRY32 structure is defined as:
I'm curious if there was some specific reason why the szExeFile entry was defined as character array instead of a fixed length string, like this:
As a string it would have allowed direct use with PB's string functions, like this:
As a character array you have to first convert it to a string, like this:
Not that big a deal, just curious.
Code: Select all
Structure PROCESSENTRY32
dwSize.l
cntUsage.l
th32ProcessID.l
th32DefaultHeapID.l
th32ModuleID.l
cntThreads.l
th32ParentProcessID.l
pcPriClassBase.l
dwFlags.l
szExeFile.c[260]
EndStructureCode: Select all
szExeFile.s{260}Code: Select all
UCase(Trim(ProcEntry32\szExeFile))Code: Select all
UCase(Trim(PeekS(@ProcEntry32\szExeFile)))