Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Convert QString to unsigned char

Convert QString to unsigned char

Scheduled Pinned Locked Moved General and Desktop
3 Posts 3 Posters 7.8k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    janaki
    wrote on last edited by
    #1

    i have a lineedit,
    i have read the text using text() and assigned to QString variable
    QString s = ui->lineedit1->text();
    i have unsigned char variable mono ;
    how should i assign QString to unsigned char mono.

    can anyone help me

    1 Reply Last reply
    0
    • D Offline
      D Offline
      dreamerindia
      wrote on last edited by
      #2

      Hi,

      after QString s = ui->lineedit1->text();
      just type "s.to" and ctrl+space you will get the list of conversions.
      hope it helps.

      ~Ravivarman~

      1 Reply Last reply
      0
      • L Offline
        L Offline
        leon.anavi
        wrote on last edited by
        #3

        Check the FAQ: "How can I convert a QString to char* and vice versa?":http://qt-project.org/faq/answer/how_can_i_convert_a_qstring_to_char_and_vice_versa

        http://anavi.org/

        1 Reply Last reply
        0

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved