Detecting 16/32 bit DLLs
-
Hi CPians, Is there an easy way to detect if a DLL is 16 or 32 bit? Also what about EXEs? Regards, Victor phpWebNotes is a page annotation system modelled after php.net. http://webnotes.sourceforge.net/demo.php[^]
-
Hi CPians, Is there an easy way to detect if a DLL is 16 or 32 bit? Also what about EXEs? Regards, Victor phpWebNotes is a page annotation system modelled after php.net. http://webnotes.sourceforge.net/demo.php[^]
Probably by looking at the header. 16-bit binaries have a NE header, 32-bit have a PE header. --Mike-- Friday's GoogleFight results: Britney Spears 2,190,000 - Erica Weichers 23 :( 1ClickPicGrabber - Grab & organize pictures from your favorite web pages, with 1 click! My really out-of-date homepage Sonork-100.19012 Acid_Helm
-
Probably by looking at the header. 16-bit binaries have a NE header, 32-bit have a PE header. --Mike-- Friday's GoogleFight results: Britney Spears 2,190,000 - Erica Weichers 23 :( 1ClickPicGrabber - Grab & organize pictures from your favorite web pages, with 1 click! My really out-of-date homepage Sonork-100.19012 Acid_Helm
Thanks for the hint :) I had a look at a 16-bit/32-bit EXEs/DLLs and noticed the NE / PE. However, all files start with MZ which most probably reflects a DOS EXE header that acts as the stub. Do you know how to retrieve the information of the NE/PE. I assume the offset in the file might be different due to different stub sizes. :~ Regards, Victor. phpWebNotes is a page annotation system modelled after php.net. http://webnotes.sourceforge.net/demo.php[^]
-
Thanks for the hint :) I had a look at a 16-bit/32-bit EXEs/DLLs and noticed the NE / PE. However, all files start with MZ which most probably reflects a DOS EXE header that acts as the stub. Do you know how to retrieve the information of the NE/PE. I assume the offset in the file might be different due to different stub sizes. :~ Regards, Victor. phpWebNotes is a page annotation system modelled after php.net. http://webnotes.sourceforge.net/demo.php[^]
Matt Pietrek, "Windows 95 System Programming Secrets", Chapter 8. May be, it will help you.
-
Hi CPians, Is there an easy way to detect if a DLL is 16 or 32 bit? Also what about EXEs? Regards, Victor phpWebNotes is a page annotation system modelled after php.net. http://webnotes.sourceforge.net/demo.php[^]
Use SHGetFileInfo. If uFlags contains the SHGFI_EXETYPE flag, the return value specifies the type of the executable file. Read in MSDN about SHGetFileInfo.
-
Use SHGetFileInfo. If uFlags contains the SHGFI_EXETYPE flag, the return value specifies the type of the executable file. Read in MSDN about SHGetFileInfo.
Thanks a lot Dudi, I finally got a chance to test it and it worked like a charm.. :-D Regards, Victor phpWebNotes is a page annotation system modelled after php.net. http://webnotes.sourceforge.net/demo.php[^]