Although the sample code presented here works only with Windows 3.1 and Windows for Workgroups, you can easily convert it and the Extensions you write to Windows NT. Once you recompile the code for 32-bit Windows, you can install the resulting DLL on the Windows NT File Manager.You must first replace the LibMain and WEP functions with the Win32 function DllEntryPoint. As with any other Windows NT DLL, you must respond to the DLL_PROCESS_ATTACH message inside this function, and, if you use Microsoft's Visual C++, call_CRT_INIT.
Adding DllEntryPoint is the only change required to convert an Extension to Windows NT code. However, Windows NT adds three notification messages that you can use to give an Extension more control over its environment: FMEVENT_HELPMENUITEM, FMEVENT_HELPSTRING, and FMEVENT_TOOLBARLOAD. By responding to these messages, your program can provide a context-sensitive help file to your Extension, display a context-sensitive help string on the File Manager's status bar, and place a button on the File Manager's toolbar. (Check your compiler's documentation the messages are relatively straightforward.)
Installing an Extension for Windows NT requires the same procedure as installing an Extension under Windows 3.1. With either environment, you can create a setup program that calls WriteprivateProfileString to add an entry to the WINFILE.INI section [AddOns]. This entry should point to the Extension DLL. Adding this entry is the last step in converting your Extension to Windows NT.