Tries to load a QWORD value from the registry key. @param p_pValueName Name of value to load. @param p_rValue Where to store value. @return Result code (ERROR_SUCCESS if it worked).
| 133 | // @return Result code (ERROR_SUCCESS if it worked). |
| 134 | // |
| 135 | long UserOverrideableRegKey::QueryQWORDValue(const wchar_t* const p_pValueName, |
| 136 | ULONGLONG& p_rValue) const |
| 137 | { |
| 138 | long res = ERROR_FILE_NOT_FOUND; |
| 139 | if (!Locked()) { |
| 140 | res = m_UserKey.QueryQWORDValue(p_pValueName, p_rValue); |
| 141 | } else { |
| 142 | res = ERROR_ACCESS_DENIED; |
| 143 | } |
| 144 | if (res != ERROR_SUCCESS && m_GlobalKey.Valid()) { |
| 145 | res = m_GlobalKey.QueryQWORDValue(p_pValueName, p_rValue); |
| 146 | } |
| 147 | return res; |
| 148 | } |
| 149 | |
| 150 | // |
| 151 | // Tries to load a GUID value from the registry key (stored as a string). |