Qt : conversion in binary, decimal and hex

Qt : conversion in binary, decimal and hex

This is a basic article for Qt : conversion in binary, decimal and hex. From this tutorial, you can know how Qt : conversion in binary, decimal and hex. Qt  have rich class to convert from a data from one data type to other. From this tutorial, I am use QString class to convert a number to binary, decimal and hex number.

Please check this main.cpp code :

This is contents for the *.pro file :

This is an output from this Qt : conversion in binary, decimal and hex code :

5 thoughts on “Qt : conversion in binary, decimal and hex

  1. Thank you very much for this tutorial.
    There are some issue in this.
    If you will convert hex 0x7FFFFFFF to int, binary it retruns 0.
    why?

    • Thank you very much for this tutorial.
      There are some issue in this.
      1) If you will convert hex 0x7FFFFFFF to int, binary it retruns 0 only.
      why?

  2. What is this, my comment automatically edited. I write something else but comment post is skips some of the lines…

Leave a Reply

Your email address will not be published. Required fields are marked *

 

This site uses Akismet to reduce spam. Learn how your comment data is processed.