Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Newbie observations on comboboxes...
Message
From
18/11/2006 16:55:46
Mike Yearwood
Toronto, Ontario, Canada
 
 
To
18/11/2006 16:41:19
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Environment versions
Visual FoxPro:
VFP 6 SP5
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01170960
Message ID:
01171014
Views:
10
Hi Miker - that's for calling me Mikey ;)

I just ran your code and it is not doing what you describe - mouse in the list area or not. It does do what I described though - that the mouse holds the highlight on a particular record even though the incremental search changes the display value - only if the mouse pointer is in the list area.

>OK, here is the code for my little form with a single combobox control on it. When I run it in VFP6 (SP5), I click on the downarrow to activate the combo's dropdown list. IF the mouse pointer is moved anywhere in the rectangular space used by the list, any keystroke will close the list. OTOH, if the mouse pointer is kept outside the list's region, then it works as one would expect, allowing full incremental searching...
>
>PUBLIC oform1
>
>oform1=NEWOBJECT("form1")
>oform1.Show
>RETURN
>
> **************************************************
>*-- Form: form1 (c:\vfp\regional\BadComboBox.scx)
>*-- ParentClass: form
>*-- BaseClass: form
>*-- Time Stamp: 11/18/06 04:32:01 PM
>*
>DEFINE CLASS form1 AS form
>
>
> Top = -1
> Left = -1
> DoCreate = .T.
> Caption = "Form1"
> Name = "Form1"
>
>
> ADD OBJECT combo1 AS combobox WITH ;
> RowSourceType = 1, ;
> RowSource = "Aaaaaa,Abaaaa,Acaaaa,Adaaaa", ;
> Height = 24, ;
> Left = 96, ;
> Top = 72, ;
> Width = 100, ;
> Name = "Combo1"
>
>ENDDEFINE
>*
>*-- EndDefine: form1
>**************************************************
>
>
>>
>>Open a form in the Class Browser and click on View Class Code button. The generated code will be dispalyed in the program editor vindow. You can run it right from there.
>>The code generated this way may not be runnable when there're containers (including grids) on the form. There's ClassBrowserX on VFPx (http://www.codeplex.com/Release/ProjectReleases.aspx?ProjectName=VFPX&ReleaseId=66) that allows to overcome such limitations.
>>
>>>So you're saying this is not a well known/documented bug in VFP? I found a UT thread describing the exact same problem. Typical responses, if I recall correctly, were "well, that's the way the combobox object works". I'll try to locate it again and reference it so maybe a consensus can be formed...
>>>
>>>As for pasting exported code, I am not sure how I would do that. I can certainly create a simple form with just a combobox dropdown list object on it and compile. How would I then export the code? Sorry, but I am very new to VFP...
>>>
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform