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. Append file
Qt 6.11 is out! See what's new in the release blog

Append file

Scheduled Pinned Locked Moved General and Desktop
6 Posts 4 Posters 3.2k 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.
  • V Offline
    V Offline
    Vidhya
    wrote on last edited by
    #1

    How can i append file (existing html file ) using QTextDocument

    Regards,
    Vidhya

    1 Reply Last reply
    0
    • JeroentjehomeJ Offline
      JeroentjehomeJ Offline
      Jeroentjehome
      wrote on last edited by
      #2

      Bit more information is needed here I think. Where do you want to append this file? Append to what??
      Do you want to add the HTML file to a QTextDocument or what?

      Greetz, Jeroen

      1 Reply Last reply
      0
      • V Offline
        V Offline
        Vidhya
        wrote on last edited by
        #3

        i need to add some additional lines to the html file

        Regards,
        Vidhya

        1 Reply Last reply
        0
        • D Offline
          D Offline
          DerManu
          wrote on last edited by
          #4

          Read the file into a string (with QFile and QTextStream) and then use "setHtml":http://doc.qt.nokia.com/4.7-snapshot/qtextdocument.html#setHtml
          Or if your question was how to append a file to an existing QTextDocument, use "insertHtml":http://doc.qt.nokia.com/4.7-snapshot/qtextcursor.html#insertHtml . It helps when you state more clearly what you actually want to do and what you have tried already.

          1 Reply Last reply
          0
          • V Offline
            V Offline
            Vidhya
            wrote on last edited by
            #5

            thank u fro ur reply i will tyr setHtml function.

            Regards,
            Vidhya

            1 Reply Last reply
            0
            • M Offline
              M Offline
              morpe
              wrote on last edited by
              #6

              @Vidhya, did you succede in your attempt?

              In my case, I want to append audio but it appears Qt 4.8 lib doesn't support HTML5 tag. Is there anyway around this limitation?

              Any advice would be highly appriciated.

              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