Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. How to send redraw message to background windows

How to send redraw message to background windows

Scheduled Pinned Locked Moved C#
helptutorialquestion
3 Posts 3 Posters 0 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.
  • M Offline
    M Offline
    manchukuo
    wrote on last edited by
    #1

    Hi guys i am doing an app where i am using ControlPaint.DrawReversibleFrame to paint the drag siluet of a rectangle over the screen but in a certain condition when a user does a mouseup i have to "animate"the movement of that rectangle so it returns to a place in the screen but when the rectangle starts to animate the movement it keeps the last position rect in the screen so it does not send the redraw message to the background windows. Can someone they me how to fix this mess?

    K L 2 Replies Last reply
    0
    • M manchukuo

      Hi guys i am doing an app where i am using ControlPaint.DrawReversibleFrame to paint the drag siluet of a rectangle over the screen but in a certain condition when a user does a mouseup i have to "animate"the movement of that rectangle so it returns to a place in the screen but when the rectangle starts to animate the movement it keeps the last position rect in the screen so it does not send the redraw message to the background windows. Can someone they me how to fix this mess?

      K Offline
      K Offline
      kevinnicol
      wrote on last edited by
      #2

      You could try making a call to System.Windows.Forms.Application.DoEvents() although that might just be for the process you call it from.

      1 Reply Last reply
      0
      • M manchukuo

        Hi guys i am doing an app where i am using ControlPaint.DrawReversibleFrame to paint the drag siluet of a rectangle over the screen but in a certain condition when a user does a mouseup i have to "animate"the movement of that rectangle so it returns to a place in the screen but when the rectangle starts to animate the movement it keeps the last position rect in the screen so it does not send the redraw message to the background windows. Can someone they me how to fix this mess?

        L Offline
        L Offline
        Luc Pattyn
        wrote on last edited by
        #3

        Hi, the way I understand it, the ControlPaint.DrawReversible methods don't need the help of other windows or processes to execute immediately, and calling them a second time undoes the drawing of the first time, so if some of them remain visible, it suggests you didn't execute them in pairs in the right order (i.e. A A B B C C). :)

        Luc Pattyn [Forum Guidelines] [Why QA sucks] [My Articles] Nil Volentibus Arduum

        Please use <PRE> tags for code snippets, they preserve indentation, and improve readability.

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups