Welcome To The Home Of The Visual FoxPro Experts  
home. signup. forum. archives. search. google. articles. downloads. faq. members. weblogs. file info. rss.
 From: Rick C. Hodgin
  Where is Rick C. Hodgin?
 Indianapolis
 Indiana - United States
 Rick C. Hodgin
 To: David Mustakim
  Where is David Mustakim?
 Jakarta
 Indonesia
 David Mustakim
 Tags
Subject: RE: "SetAll" for Click on a Grid's component
Thread ID: 365611 Message ID: 365648 # Views: 32 # Ratings: 0
Version: Visual FoxPro 9 SP2 Category: Grids
Date: Saturday, December 29, 2012 5:18:36 AM         
   


> >
> >
> > I was believing that clicking on the column header would cause a column change, and therefore fire the before/afterRowColChange events. But I just tested this and I was wrong.
> >
> > Good eye, sir (and knowledge base). :-)
> >
> > It's an interesting challenge. It comes down to being able to trigger specific code based on variables that are not known at design time, and can't easily be coded at runtime without accounting for the entire range of anticipated variables explicitly (a class for every column width possibility, or at least a max that's later pared down), or the more general necessity of programmatically processing through mouseMove data manually to produce the intended effect of the desired mouse stroke.
> >
> > I think in my app I would still use the mouseCatch transparent shape in a new gridCatch class, one designed to translate its mouse coordinates to a brief algorithm which determined which column to fire upon, and in that way send appropriate mouseMove/Enter/Leave/Down events.
> >
> > Best regards,
> > Rick C. Hodgin
>
>
> Earlier I was trying the to bind event the "mouseup" (rather than "click") since it has the x,y parameters but somehow was still unsuccessful in getting the figures right even after playing with different "nflags"... would that likely be easier than employing added transparent shape which may entail more complex calculation??...
>
> David
> ..
> .



I think technically the MouseMove and MouseDown events at the grid level could be used by themselves in lieu of the transparent shape, but using something like a transparent shape offers an easily copyable object without creating a new class, or the requirement of a class object as with bindevent().

I think it depends on personal tastes at this point as any of the three approaches are similarly equipped in functionality and ease of programming.

Best regards,
Rick C. Hodgin

ENTIRE THREAD

"SetAll" for Click on a Grid's component Posted by Ilya Rabyy @ 12/28/2012 4:52:02 PM
RE: "SetAll" for Click on a Grid's component Posted by Koen Piller @ 12/28/2012 6:24:59 PM
RE: "SetAll" for Click on a Grid's component Posted by Ilya Rabyy @ 12/28/2012 6:34:36 PM
RE: "SetAll" for Click on a Grid's component Posted by David Mustakim @ 12/28/2012 7:29:23 PM
RE: "SetAll" for Click on a Grid's component Posted by Ilya Rabyy @ 12/28/2012 7:37:06 PM
RE: "SetAll" for Click on a Grid's component Posted by David Mustakim @ 12/28/2012 7:51:06 PM
RE: "SetAll" for Click on a Grid's component Posted by Ilya Rabyy @ 12/28/2012 8:18:54 PM
RE: "SetAll" for Click on a Grid's component Posted by David Mustakim @ 12/28/2012 8:27:51 PM
RE: "SetAll" for Click on a Grid's component Posted by Ilya Rabyy @ 12/28/2012 8:46:01 PM
RE: "SetAll" for Click on a Grid's component Posted by David Mustakim @ 12/30/2012 2:15:11 AM
RE: "SetAll" for Click on a Grid's component Posted by David Mustakim @ 12/28/2012 8:00:31 PM
RE: "SetAll" for Click on a Grid's component Posted by Rick Hodgin @ 12/28/2012 10:08:56 PM
RE: "SetAll" for Click on a Grid's component Posted by Ilya Rabyy @ 12/28/2012 10:39:58 PM
RE: "SetAll" for Click on a Grid's component Posted by David Mustakim @ 12/28/2012 11:21:00 PM
RE: "SetAll" for Click on a Grid's component Posted by Rick Hodgin @ 12/29/2012 12:15:55 AM
RE: "SetAll" for Click on a Grid's component Posted by David Mustakim @ 12/29/2012 4:30:20 AM
RE: "SetAll" for Click on a Grid's component Posted by David Mustakim @ 12/29/2012 4:41:23 AM
RE: "SetAll" for Click on a Grid's component Posted by Rick Hodgin @ 12/29/2012 5:18:36 AM
RE: "SetAll" for Click on a Grid's component Posted by David Mustakim @ 12/30/2012 2:21:33 AM
RE: "SetAll" for Click on a Grid's component Posted by Rick Hodgin @ 12/30/2012 2:40:52 AM
RE: "SetAll" for Click on a Grid's component Posted by David Mustakim @ 12/30/2012 3:00:46 AM
RE: "SetAll" for Click on a Grid's component Posted by Rick Hodgin @ 12/30/2012 3:09:49 AM
RE: "SetAll" for Click on a Grid's component Posted by David Mustakim @ 12/30/2012 3:19:19 AM
RE: "SetAll" for Click on a Grid's component Posted by Rick Hodgin @ 12/30/2012 4:52:53 AM
RE: "SetAll" for Click on a Grid's component Posted by Samir H. @ 12/30/2012 7:09:16 AM
RE: "SetAll" for Click on a Grid's component Posted by Rick Hodgin @ 12/30/2012 2:33:42 PM
RE: "SetAll" for Click on a Grid's component Posted by Rick Hodgin @ 12/28/2012 6:53:02 PM
RE: "SetAll" for Click on a Grid's component Posted by Samir H. @ 12/29/2012 7:51:58 AM
RE: "SetAll" for Click on a Grid's component Posted by David Mustakim @ 12/29/2012 11:27:36 AM
RE: "SetAll" for Click on a Grid's component Posted by Anders Altberg @ 12/30/2012 3:08:19 PM