HighTechTalks DotNet Forums  

double-click in DataGrid

Dotnet General Discussions microsoft.public.dotnet.general


Discuss double-click in DataGrid in the Dotnet General Discussions forum.



Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old   
ChrisJ
 
Posts: n/a

Default double-click in DataGrid - 12-19-2007 , 08:35 PM






I am using a datagrid as a selection list on a form.
There is an OK button which closes the form and returns the current selection.
I would like to get a doubleclick to perform the same action
Click, and doubleclick events only occur when the non-cell area of the
datagrid is clicked.
I wrote code in the mousedown event of the DG using hittest, and this works
fine for a single click in a cell (i'm trapping for a click anywhere in a
row).
but for subsequent clicks in the same cell, the cell goes into edit mode and
swallows the event so that the mousedown no longer fires.

I've tried locking the DG and making it read only with no change in
behaviour, and disbaling the DG give no mousedowns at all

Any suggestions??

Reply With Quote
Reply




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.