Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. General talk
  3. Qt 6
  4. parse strings with tags
QtWS25 Last Chance

parse strings with tags

Scheduled Pinned Locked Moved Unsolved Qt 6
5 Posts 3 Posters 603 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.
  • F Offline
    F Offline
    fari35
    wrote on last edited by fari35
    #1
    This post is deleted!
    JonBJ 1 Reply Last reply
    0
    • F fari35

      This post is deleted!

      JonBJ Offline
      JonBJ Offline
      JonB
      wrote on last edited by
      #2

      @fari35
      Your code seems to have nothing to do with Qt. Goodness knows how it works. It sounds like all you want do is use QRegularExpression and QString::replace(const QRegularExpression &re, const QString &after).

      1 Reply Last reply
      0
      • SGaistS Offline
        SGaistS Offline
        SGaist
        Lifetime Qt Champion
        wrote on last edited by
        #3

        Hi,

        Are you working with XML data ?

        Interested in AI ? www.idiap.ch
        Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

        F 1 Reply Last reply
        0
        • SGaistS SGaist

          Hi,

          Are you working with XML data ?

          F Offline
          F Offline
          fari35
          wrote on last edited by
          #4

          @SGaist Actually I have made a client that will send the messages with tags like the one I have shown, so I have to change the values of tags. I have been told to use std::string.find() and std::string.substr(). but I am not getting the required output.

          1 Reply Last reply
          0
          • SGaistS Offline
            SGaistS Offline
            SGaist
            Lifetime Qt Champion
            wrote on last edited by
            #5

            Why did you delete the question ?

            As for the edition, since you control the tags, then QRegularExpression and QString should fit well.

            Interested in AI ? www.idiap.ch
            Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

            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