Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Erratic combobox behavior
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 6 SP5
OS:
Windows 2000 SP4
Network:
Windows 2000 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01060242
Message ID:
01060342
Views:
23
The combo box data stays pretty constant. I am adding data related to the combo box value to the grid. I was using the laskey function to keep the valid/lostfocus from firing on a pass thru.

The lastkey value for entering numeric values ranges from 48 to 57. I was trapping for tab(9) or enter(13), that is why the code would not run. This feels like a sloopy way to code this but I need the valid/lostfocus to not fire if the close or cancel button is clicked or the user is arrowing thru the combo boxes.

Sorry if I wan't clearer earlier. Since this was an intermittent problem and it did not raise its ugly head until I recompiled it, I have been really frustrated with it.

Chuck

>Right
>
>No need to get shirty. I've been working exclusively in MapInfo and MapBasic for 2 weeks so terminology is a bit shaky. When you referred to rows I thought you were talking about combobox rows.
>
>Now then, have you tried the interactivechange event of the combo? If I understand you, and your addendum to this message, you're not always adding to the combo, so valid wouldn't fire?
>
>>Ok smarty pants, what should I have called it? The method use to be in the combobox valid and did the same thing. I created the method thinking the pointer movement would change its behavior and it didn't. Its like the code never runs. I suspended the process in debug, AFTER the method ran and manually did a parent refresh in the command window and no data appeared which means to me the code did not execute because no values are in memory. Problem is sometimes it works and I donot know how to trap it.
>>
>>>Chuck
>>>
>>>So why did you head your thread "erratic combobox behavior"? What's happening/ not happening exactlty to the combo?
>>>
>>>
>>>>Terry
>>>>Its not the combo that needs refreshing, its the grid. Yes I do have a gridRefresh method that runs in the valid after the grid columns are supposed to be updated. Its like the code never runs, but in debuf step mode it works, so weird.
>>>>
>>>>>Chuck
>>>>>
>>>>>Not sure whether you're saying here that the combobox is not refreshed - there's no mention of it in your sample code. Off the top of my head:
>>>>> are you .Refresh()ing the combo after you add values to its source?
>>>>> are you .Requery()ing it?
>>>>>
>>>>>HTH
>>>>>
>>>>>Terry
Extreme Programming = Plan -> Design -> Code -> Test
Previous
Reply
Map
View

Click here to load this message in the networking platform