This project is read-only.

Make ATLPref work under Vista


The pref objects don't work under Vista, there seem to be two problems with it:


ShayEr wrote Jul 8, 2008 at 3:13 PM

  1. The "Configuration Flags" value that has been added to Vista to protect the Counter value.
  2. rkLang.QueryMultiStringValue(..) returns "The data is invalid", 0x8007000d. (at least when compiling under ANSI I haven't tested it under Unicode)

audriusz wrote Dec 28, 2010 at 3:14 PM

I had encountered supposedly the same issue on Windows Server 2008 R2. I believe that this is the result of a problem inside RegQueryValueEx, by including uninitialized data into the reported byte array. As with other uninitialized data, reproducing the problem is quite random.
I have submitted the issue via Microsoft Connect (

A simple workaround may be coded into ATL Server, <atlperf.inl>:
Metods CPerfMon::_AppendRegStrings and CPerfMon::_RemoveRegStrings should zero-fill the buffer inside CStrBuf passed as a parameter to the second calls to rkLang.QueryMultiStringValue.

wrote Feb 14, 2013 at 8:57 PM

icnocop wrote Apr 11, 2013 at 2:09 AM

There is a duplicate issue here: Perfomance Counter Support in Vista