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. Flush: BitBlt failed (The handle is invalid.)
QtWS25 Last Chance

Flush: BitBlt failed (The handle is invalid.)

Scheduled Pinned Locked Moved General and Desktop
7 Posts 2 Posters 3.7k 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.
  • B Offline
    B Offline
    BasicPoke
    wrote on last edited by
    #1

    I am getting the following written to the Application Output:
    @flush: BitBlt failed (The handle is invalid.)@
    Can you please point me in the direction of what this might be? It happens maybe every few minutes. My app is in a loop that receives data from a DAQ on a USB port, processes the data using QList<qint8>'s, QStrings, arrays, etc. and posts results on a QTableWidget.
    Thanks
    Ron

    1 Reply Last reply
    0
    • A Offline
      A Offline
      ambershark
      wrote on last edited by
      #2

      Well a bit blit would be a write to a graphic object. Usually it is used in 3D stuff or direct screen writes to a screen memory buffer.

      Is this causing problems with your app? If so do you have an opengl view anywhere or any other graphics view (even 2d)?

      It could have to do with opengl, but there isn't enough information here. I don't know what Qt version, OS, or how it was compiled (opengl or not).

      My L-GPL'd C++ Logger github.com/ambershark-mike/sharklog

      1 Reply Last reply
      0
      • B Offline
        B Offline
        BasicPoke
        wrote on last edited by
        #3

        I'm not using any graphics objects that I am aware of when the errors occur. The only graphics in the app is writing text to items in the QTableWidget and changing the item background colors. But I can see the errors occur at a time when I am not writing to the table.

        Yes it is causing problems with my app, causing data packets to have a parity mismatch, but I don't know exactly where it's causing the problem. I don't know what an OpenGL view or other graphics view is, so I'm thinking I don't have those. I have QActions, QTableWidget, QPlainTextEdits, QPushButtons, QLabels, and a QCheckBox.

        Windows 7 Enterprise 64-bit
        Qt Creator 3.0.1
        Desktop Qt 5.2.1 MinGW 32 bit

        Ron

        1 Reply Last reply
        0
        • A Offline
          A Offline
          ambershark
          wrote on last edited by
          #4

          Ok yea you don't have anything that would use a bit blit unless there is something deep in Qt's internals that uses that even for simple GUI objects. But I don't think so.

          It may or may not be the problem with your data packets. I am kind of leaning towards it not being your problem, however since there is a bad handle it's possible that there was some heap or stack corruption which is causing the bad data packets too. This is kind of a reach though since you'd more than likely see a segmentation fault if that was the case.

          I'm thinking the flush problem is not related to your packets though but I will do some research and see if I can find anything related to it for you.

          My L-GPL'd C++ Logger github.com/ambershark-mike/sharklog

          1 Reply Last reply
          0
          • A Offline
            A Offline
            ambershark
            wrote on last edited by
            #5

            Ok so I found a "bug":https://bugreports.qt-project.org/browse/QTBUG-29716 that was causing that in Qt. It seems to be solved in 5.3. Just upgrade your Qt and the flush bitblt problem will go away.

            However I don't think that it is the problem you are having with your data packets.

            My L-GPL'd C++ Logger github.com/ambershark-mike/sharklog

            1 Reply Last reply
            0
            • B Offline
              B Offline
              BasicPoke
              wrote on last edited by
              #6

              Thanks ambershark. Qt download is blocked here at work (gotta be safe), or I would do that right now.

              1 Reply Last reply
              0
              • A Offline
                A Offline
                ambershark
                wrote on last edited by
                #7

                Hopefully that fixes it. I think you still have to find your data packet issue though. Good luck on that. :-)

                My L-GPL'd C++ Logger github.com/ambershark-mike/sharklog

                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