Pass a Hex value into a unsigned int function

J

Jason

Hello


I've got a get hex value 0X500000 and I'd like to pass it into a function
that has a signature of Foo(unsigned int * address) {}

Do I need to convert the hex value to type INT? How would I do that?

Thanks
 
D

David Wilkinson

Jason said:
Hello


I've got a get hex value 0X500000 and I'd like to pass it into a function
that has a signature of Foo(unsigned int * address) {}

Do I need to convert the hex value to type INT? How would I do that?

I'm not sure what you are really asking. Why not just

unsigned int n = 0X500000;
Foo(&n);

?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top