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. WPF
  4. Mouse up/down events

Mouse up/down events

Scheduled Pinned Locked Moved WPF
questionhelpannouncement
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.
  • C Offline
    C Offline
    columbos14927
    wrote on last edited by
    #1

    Hello, I have something strange, i have defined two Event Triggers with atched commands in my button:

    LEFT MOUSE BUTTON SCENARIO: When i use those Events:MouseLeftButtonDown ,MouseLeftButtonUp the StartCommand invoked when i press(with left mouse button) down the button but when i relese the mouse the stop command is not invoked. RIGHT MOUSE BUTTON SCENARIO: When i use those Events:MouseRightButtonDown ,MouseRightButtonUp the StartCommand invoked when i press(with right mouse button) down the button and the StopCommand invoked when i release the button as expected. What is the problem why the StopCommand is not invoked? How can i fire off a command when a button is pressed(with left mouse button) and fire off another command when the button released? Thanks

    Richard DeemingR A 2 Replies Last reply
    0
    • C columbos14927

      Hello, I have something strange, i have defined two Event Triggers with atched commands in my button:

      LEFT MOUSE BUTTON SCENARIO: When i use those Events:MouseLeftButtonDown ,MouseLeftButtonUp the StartCommand invoked when i press(with left mouse button) down the button but when i relese the mouse the stop command is not invoked. RIGHT MOUSE BUTTON SCENARIO: When i use those Events:MouseRightButtonDown ,MouseRightButtonUp the StartCommand invoked when i press(with right mouse button) down the button and the StopCommand invoked when i release the button as expected. What is the problem why the StopCommand is not invoked? How can i fire off a command when a button is pressed(with left mouse button) and fire off another command when the button released? Thanks

      Richard DeemingR Offline
      Richard DeemingR Offline
      Richard Deeming
      wrote on last edited by
      #2

      Have you tried using PreviewMouseLeftButtonUp?


      "These people looked deep within my soul and assigned me a number based on the order in which I joined." - Homer

      "These people looked deep within my soul and assigned me a number based on the order in which I joined" - Homer

      1 Reply Last reply
      0
      • C columbos14927

        Hello, I have something strange, i have defined two Event Triggers with atched commands in my button:

        LEFT MOUSE BUTTON SCENARIO: When i use those Events:MouseLeftButtonDown ,MouseLeftButtonUp the StartCommand invoked when i press(with left mouse button) down the button but when i relese the mouse the stop command is not invoked. RIGHT MOUSE BUTTON SCENARIO: When i use those Events:MouseRightButtonDown ,MouseRightButtonUp the StartCommand invoked when i press(with right mouse button) down the button and the StopCommand invoked when i release the button as expected. What is the problem why the StopCommand is not invoked? How can i fire off a command when a button is pressed(with left mouse button) and fire off another command when the button released? Thanks

        A Offline
        A Offline
        Ashfaque Hussain
        wrote on last edited by
        #3

        can you post the code for Mouse down

        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