General information
Category:
Forms & Form designer
Title:
Combobox DisplayValue Bug Revisited
Hi All,
Here's another contribution to the DisplayValue bugginess:
Run the following code. When you select an item from the Top Combobox, the 2nd Combo Box gets the Focus and Displays it's items. The problem is that the Top Combo Box which has a Control Source to a numerical Form Property will only display properly if on the first List Item. Remove the Control Source propery Value on Combo1 and everything works fine...Anyone from Microsoft out there?
PUBLIC oform1
oform1=NEWOBJECT("form1")
oform1.Show
RETURN
**************************************************
*-- Form: form1 (d:\rainbow\combobug.scx)
*-- ParentClass: form
*-- BaseClass: form
*-- Time Stamp: 01/31/06 09:20:07 PM
*
DEFINE CLASS form1 AS form
Height = 138
Width = 167
DoCreate = .T.
AutoCenter = .T.
Caption = "Form1"
nnumber = ( 0)
Name = "Form1"
ADD OBJECT combo1 AS combobox WITH ;
BoundColumn = 2, ;
ColumnCount = 2, ;
ColumnWidths = "80,0", ;
RowSourceType = 1, ;
RowSource = "One,1,Two,2,Three,3,Four,4", ;
ControlSource = "THISFORM.nNumber", ;
Height = 24, ;
ColumnLines = .F., ;
Left = 24, ;
Style = 2, ;
Top = 24, ;
Width = 100, ;
BoundTo = .T., ;
Name = "Combo1"
ADD OBJECT combo2 AS combobox WITH ;
ColumnCount = 1, ;
RowSourceType = 1, ;
RowSource = "Value1,Value2,Value3,Value4", ;
Height = 24, ;
Left = 24, ;
Style = 2, ;
Top = 72, ;
Width = 100, ;
Name = "Combo2"
PROCEDURE combo1.InteractiveChange
WITH THISFORM.Combo2
.SetFocus()
KEYBOARD '{F4}' PLAIN CLEAR
ENDWITH && WITH THISFORM.Combo2
ENDPROC
ENDDEFINE
*
*-- EndDefine: form1
**************************************************
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only