Why do mouse clicks pass through the file

This is a discussion on Why do mouse clicks pass through the file within the C# Programming forums, part of the General Programming Boards category; when i go to open a file with a file dialog box, i double click on the file i want ...

  1. #1
    Registered User
    Join Date
    Oct 2008
    Posts
    85

    Why do mouse clicks pass through the file

    when i go to open a file with a file dialog box, i double click on the file i want to open, the file opens ok but the clics are passed to the underlying control and my program picks them up. should this happen ? and can i stop it anyway ?

    do i need to temporarily disable the control during the file method or something?

    its very annoying - i thought the mouse handlers for the open form would take care of it but apparently it isnt :S

  2. #2
    Registered User
    Join Date
    Oct 2008
    Posts
    85
    i have recieved a solution to this problem now so please consider this thread closed.

    the problem was the mouse_up event was firing after the fileopendialog had closed ( it happens too damn fast) and was being picked up by the underlying control firing my mouse_up event handler.

    this can be worked around by using the 'control.capture = true;' & 'control.capture = false' to flag it as being handled/unhandled.

    hope this helps someone else.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. opening empty file causes access violation
    By trevordunstan in forum C Programming
    Replies: 10
    Last Post: 10-21-2008, 11:19 PM
  2. Speed test result
    By audinue in forum C Programming
    Replies: 4
    Last Post: 07-07-2008, 05:18 AM
  3. Formatting a text file...
    By dagorsul in forum C Programming
    Replies: 12
    Last Post: 05-02-2008, 03:53 AM
  4. Formatting the contents of a text file
    By dagorsul in forum C++ Programming
    Replies: 2
    Last Post: 04-29-2008, 12:36 PM
  5. System
    By drdroid in forum C++ Programming
    Replies: 3
    Last Post: 06-28-2002, 10:12 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21