CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    May 1999
    Posts
    20

    Hex Value to unsigned long



    Could anyone explain how I can convert an hex value to binary base2 eg.


    I need to read 4 bytes Hex and append them to create a 32bit value in Base 2


    HEX DECIMAL BINARY(REQUIRED)

    43CAFAE0 -> 67202250224 -> 10000111100111010111000001


    I have not found any refrence to base in VB and C++ strtoul does not out put

    the binary value in base 2


    eg strtoul(Value, *endptr, 2) will out put values like 0


    any help welcome

    Regards Mark

  2. #2
    Join Date
    May 1999
    Location
    Oxford UK
    Posts
    1,459

    Re: Hex Value to unsigned long



    Hi


    Take a look at :


    http://www.planet-source-code.com/vb...txtCodeId=1474


    Regards


    Chris Eastwood


    CodeGuru - the website for developers

    http://www.codeguru.com/vb

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured