>>>* cough * Um, Mike, I don't think that he specifically asked about setting the default printer. He asked about reading/writing registry keys.
>>
>>Um, yeah, but the article shows how to use GetProfileString(), which could accomplish what he's looking for. I'll admit the article isn't going to give cut-and-paste code, but I don't want to just
give him the fish. :-)
>
>OIC. While I've got you "on the hook" < wg >, would this stuff work with Win2K as well? Especially the setting the default printer part.
My guess is that anything that maps directly to an entry in WIN.INI or SYSTEM.INI that lives in the registry will be accessible through the ProfileString Win16 APIs, but that's pure speculation; I've never tried it under Win2K. I know that the SYSTEM.INI mappings for ME do translate to real registry entries; I can make changes through GetPrivateProfileString() and WritePrivateProfileString(), and SYSEDIT does display limited WIN.INI and SYSTEM.INI files under Win2K, and the DOS Environment variables are under HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\SessionManager\Environment and are command line or API-adjustable as always. But this is guesswork; I have no FPW to support.