Rafael:
Thanks for all your suggestions.
I will try it.
Currently I have a method fire when the row is selected telling the user that 
it is not available for selection. I thought a cleaner approach would be not 
allow the row to be selected at all by disabling it and show disabled colors.
Thanks!
Regards,

Jack

________________________________________
From: [email protected] [[email protected]] On Behalf Of 
Rafael Copquin [[email protected]]
Sent: Monday, June 22, 2009 10:08 AM
To: [email protected]
Subject: Re: VFP9 SP2: How to disbale a row in a grid

If you set the deletemark property to false, the deleted record will not
show. If you still want to show it, you could use an extra column with a
checkbox set as the current control, that would, using the dynamic
properties, be marked or unmarked, depending on whether the record has been
deleted or not. By the same token, you can avoid it being chosen using the
dynamic properties.

Event though it apparently is not related, you could use the dynamicfontbold
property of the column, having it call a method in the form to disable or
enable the column if it is deleted or not.

for instance

thisform.grid1.column1.dynamicfontbold = thisform.enablecol()

and you put the necessary code in the enablecol method. Because this dynamic
property changes dynamically (how more redundant can I be?), the call to the
method will be made for each record, and in this way, the method will cause
the checkbox in the suggested extra column to be marked or not.

Hope it helps

Rafael Copquin



----- Original Message -----
From: "Jack Skelley" <[email protected]>
To: <[email protected]>
Sent: Friday, June 19, 2009 2:11 PM
Subject: RE: VFP9 SP2: How to disbale a row in a grid


> Rick:
> Thanks...I looked at that and had it call a method but it still allowed
> the user to click the deleted record.
> I currently am using the dynamicforecolor to change the color based on the
> record state. I currently tell the user it can't be selected.
> What I really wanted was the user not to be able to select the row.
> I guess this is ok for now.
> Thanks for the suggestion.
> Regards,
>
> Jack
>
>
> ________________________________________
> From: [email protected] [[email protected]] On
> Behalf Of Rick Schummer [[email protected]]
> Sent: Friday, June 19, 2009 12:58 PM
> To: [email protected]
> Subject: RE: VFP9 SP2: How to disbale a row in a grid
>
>>> How do you disable a row in a grid when the record in the recordsource
> has been marked for deletion. I want the item to show but not allow it fo
> be
> selected.<<
>
> You can use DynamicCurrentControl to swap out controls, one enable and one
> disabled. Use the Deleted() state to toggle which controls are displayed.
>
> Rick
> White Light Computing, Inc.
>
> www.whitelightcomputing.com
> www.swfox.net
> www.rickschummer.com
>
>
>
[excessive quoting removed by server]

_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: 
http://leafe.com/archives/byMID/profox/0b957900b2b8194d998a441195b66038386be4b...@drdsrv03.drdad.thenewarkarena.com
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to