Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. [solved] deleting a line

[solved] deleting a line

Scheduled Pinned Locked Moved QML and Qt Quick
3 Posts 3 Posters 3.4k Views 1 Watching
  • 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.
  • S Offline
    S Offline
    spode
    wrote on last edited by
    #1

    i have this txt file:
    "

    lightblue
    erklärung
    Eine erklärung machen
    Spiegazione

    false
    ENDB

    green
    bei

    presso

    false
    ENDB

    green
    bei
    sono nei pressi
    ciao

    true
    ENDB

    green
    wort
    das ist es
    parola
    questo è
    false
    ENDB

    "

    how can i delete a part of it, for example the following?
    "green
    bei

    presso

    false
    ENDB"

    1 Reply Last reply
    0
    • G Offline
      G Offline
      giesbert
      wrote on last edited by
      #2

      Load it into memory, delete the content from the String in the memory and stroe it again. Directly deleting in the file is not possible.

      Nokia Certified Qt Specialist.
      Programming Is Like Sex: One mistake and you have to support it for the rest of your life. (Michael Sinz)

      1 Reply Last reply
      0
      • S Offline
        S Offline
        srikanth_trulyit
        wrote on last edited by
        #3

        If content is newline delimited, load it to QStringList and delete required items.

        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