Results 1 to 3 of 3

Thread: unsigned char * to QString

  1. #1
    Join Date
    Mar 2009
    Posts
    2
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11

    Default unsigned char * to QString

    I wish covert unsigned char *ch to QString

    How could I do?
    Could you give me some code?

  2. #2
    Join Date
    Jan 2006
    Location
    Germany
    Posts
    4,380
    Thanks
    19
    Thanked 1,005 Times in 913 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows Symbian S60
    Wiki edits
    5

    Default Re: unsigned char * to QString

    A constructor is QString ( const char * str ). Doesn't it work?
    Qt Code:
    1. QString str(ch);
    To copy to clipboard, switch view to plain text mode 

  3. #3
    Join Date
    Mar 2009
    Posts
    2
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11

    Default Re: unsigned char * to QString

    yes,it works now! thx!!!

Similar Threads

  1. Char array[6] to QString and display it
    By arunvv in forum Newbie
    Replies: 11
    Last Post: 12th March 2014, 20:48
  2. convert unsigned char * to QString
    By sepehr in forum Qt Programming
    Replies: 4
    Last Post: 9th December 2008, 20:31
  3. QString to unsigned char *
    By darksaga in forum Qt Programming
    Replies: 9
    Last Post: 23rd July 2007, 07:52
  4. Convert from iso-8859-1 to... Something else :-)
    By Nyphel in forum Qt Programming
    Replies: 4
    Last Post: 7th March 2007, 17:59
  5. unable to save QCStrings properly in a buffer
    By nass in forum Qt Programming
    Replies: 13
    Last Post: 15th November 2006, 20:49

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.