displaying hex characters

This is a discussion on displaying hex characters within the C++ Programming forums, part of the General Programming Boards category; hi, my questions is about displaying hex characters. I am trying to create a program that prints out bytes 5 ...

  1. #1
    Registered User
    Join Date
    Apr 2008
    Posts
    99

    displaying hex characters

    hi, my questions is about displaying hex characters. I am trying to create a program that prints out bytes 5 to 10 but I dont want to print the ascii characters. I would like to print out the hex values of bytes 5 to 10. Can this be done becasue no matter what i try I either get the integer values of each byte or there ascii representation


    thanks

  2. #2
    C++まいる!Cをこわせ! Elysia's Avatar
    Join Date
    Oct 2007
    Posts
    22,538
    std::cout << std::hex << number;
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Replies: 10
    Last Post: 07-10-2008, 03:45 PM
  2. Replies: 11
    Last Post: 03-24-2006, 10:26 AM
  3. ascii characters video displaying on tv screen
    By deian in forum C Programming
    Replies: 6
    Last Post: 10-12-2004, 09:46 PM
  4. French characters not displaying on MS DOS Window
    By CookieMonster in forum C Programming
    Replies: 21
    Last Post: 04-05-2004, 09:54 AM
  5. Replies: 1
    Last Post: 04-05-2002, 10:19 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21