REG_QWORD undeclared

Hi Experts,

I want to write a 64 bit number to the registry and was trying to use the registry value type
of REG_QWORD.  But, I get the undeclared variable compile error.  Is there any header files I need to include.  REG_DWORD has no problem.

LVL 1
thaneshAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

AxterCommented:
Hi thanesh,
> REG_QWORD
It's in the winnt.h header

David Maisonave (Axter)
Cheers!
0
jkrCommented:
However, you'll need to have an up-to-date PlatformSDK installed. E.g. VC6 does not know about that. If you don't have one, you could still use REG_BINARY.
0
thaneshAuthor Commented:
Thanks, I don't have platform SDK installed.  How is REG_BINARY different from a REG_QWORD?
0
jkrCommented:
Syntactically - not at all, you could just use

__int64 llValue = 42;
DWORD dwType = REG_BINARY;
DWORD dwSize = sizeof(__int64);

RegSetValueEx(hKey,"SomeValue",0,dwType,(LPBYTE)&llValue,dwSize);

where you otherwise would set

DWORD dwType = REG_QWORD;

But, if you have VC++ 7.x, REG_QWORD should be supported.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
C++

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.