How do i convert char * to DWORD_PTR

hi,

How do i convert char * to DWORD_PTR or DWORD
jyotishbAsked:
Who is Participating?
 
AlexFMConnect With a Mentor Commented:
Just use simple casting:

char* p;
...

DWORD_PTR ptr = (DWORD_PTR)p;
DWORD dw = (DWORD)p;

Or C++ casting:

DWORD_PTR ptr = static_cast<DWORD_PTR>(p);
DWORD dw = static_cast<DWORD>(p);
0
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.

All Courses

From novice to tech pro — start learning today.