Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Combobox question
Message
From
12/12/2008 00:00:21
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
Visual FoxPro
Application:
Desktop
Miscellaneous
Thread ID:
01366823
Message ID:
01366836
Views:
10
>What is your bound column? I would probably set it up to display description as a first column and value as a second.
>

I didn't specify:
Specifies the number of the column that is bound to the Value property. The default for nCol is 1.
Here is a clue. This control with two chars works as intended:
define class CboUnitType as CboList
    name                = "CboUnitType"
    ColumnCount         = 2
    columnwidths        = "30,180"          
    DisplayCount        = 12
    inputmask           = "XX"
    rowsource           = "  ,any type,BL,blank lot,CB,cabin (unattached),"   ;
        + "CN,condo (townhouse),PF,platform,RM,room (no kitchen),"  ;
        + "TE,tent,TR,trailer,UL,undeveloped lot,WL,whole lot,XL,discontinued lot"
    value               = "  "
    width               = 48
    statusbartext = "Enter a unit type:  BL, CB, CN, PF, RM, TE, TR, UL, WL, XL"
    tooltiptext   = "Unit Type Code"
enddefine    && CboUnitType  *************************************************

add object txtSUITEcUnitType as CboUnitType with ;
    controlsource  = "SUITE.cUnitType", ;
    top            = hnDataRow, ;
    left           = this.txtSUITEiBlockNum.left + this.txtSUITEiBlockNum.width + 6, ;
    name = "txtSUITEcUnitType"

define class CboDepHow as CboList
    name                = "CboDepHow"
    ColumnCount         = 2
    columnwidths        = "30,180"         
    displaycount        = 12
    inputmask           = "XX"
    rowsource           = "CA,cash,CC,credit card,CK,check,ND,no deposit"
    value               = "  "
    width               = 48
    statusbartext = "How the deposit is paid:  CA-cash, CC-credit card, CK-check, ND-no deposit"
    tooltiptext   = "Deposit code: CA, CC, CK, ND"
enddefine    && CboDepHow  *************************************************

add object txtSTAYcDepHow as CboDepHow with ;
    controlsource = "STAY.cDepHow", ;
    top           = hnCheckRow + hnRows2, ;
    left          = this.txtSTAYnDepDue.left + this.txtSTAYnDepDue.width + 4, ;
    name          = "txtSTAYcDepHow"
I've modified the CboDepHow class to look as much as possible like the CboUnitType class. No luck! CboUnitType works and CboDepHow doesn't.

Wierd.

Peter
Peter Robinson ** Rodes Design ** Virginia
Previous
Reply
Map
View

Click here to load this message in the networking platform