Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Finding if item is disabled in listbox
Message
From
24/02/1998 14:00:46
 
 
To
24/02/1998 13:51:44
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00079496
Message ID:
00080857
Views:
43
>Problem is that the documented way the list box is to work is to not allow
>selection of disabled row. Point I tried to make was that current VFP has
>known bug that allows user to up arrow / down arrow onto a disabled row and
>then press {Enter] and have the disabled row selected. I did not keep the
>Microsoft Bug description, but it is available at the MicroSoft site. My
>meager attempt to help was simply to warn you that despite your best
>efforts, you may see disabled row(s) selected. Sorry if I confused you, but
>thought I might save you some heartache in trying to figure out how users
>are able to select disabled row(s).

Following is quick fix:
*** List.Init event
this.additem("q1")
this.additem("q2")
this.additem("\q3"+space(3))
this.additem("q4")
*** List.Keypress event
LPARAMETERS nKeyCode, nShiftAltCtrl
if nKeycode=5 or nKeycode=24
 this.tag=this.value
endif
*** List.Interactivechange event
if empty(right(this.value,3))
 this.value=this.tag
 this.tag=""
endif
Edward Pikman
Independent Consultant
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform