Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Disabled combobox items
Message
General information
Forum:
Visual FoxPro
Category:
Other
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
MS SQL Server
Miscellaneous
Thread ID:
01358375
Message ID:
01358379
Views:
17
You've to add '\' to the second column as well
    lcItem2 = TRANSFORM(lnIndex)
    IF MOD(lnIndex, 2) = 0
       lcItem2 = "\" + lcItem2
    ENDIF
    This.AddListItem(lcItem2, This.NewIndex, 2)
>I have a combobox that where I need to show some of the items disabled. If there is only one column, it works fine. If I have multiple columns, it doesn't disable the item.
>
>Here's some sample code - drop a combo on a form and add this to the Init() of the combo:
>
>
>FOR lnIndex = 1 TO 10
>    lcItem = SYS(2015)
>    IF MOD(lnIndex, 2) = 0
>       lcItem = "\" + lcItem
>    ENDIF
>    
>    This.AddListItem(lcItem)
>    * Uncomment this line to see the issue.
>    *This.AddListItem(TRANSFORM(lnIndex), This.NewIndex, 2)
>ENDFOR
>
>
>What am I missing?
--sb--
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform