Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Can't scroll in combobox??
Message
From
16/12/2020 07:14:11
Lutz Scheffler
Lutz Scheffler Software Ingenieurbüro
Dresden, Germany
 
 
To
16/12/2020 03:06:55
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
01677575
Message ID:
01677601
Views:
78
Comboboxes are a pain anyway. I try to use for as little items as possible an pop up a pick form if it goes larger.
Anyway I found a combobox that as 4 times as much elements then the visible area covers. Scrollbar is visible.
I open the list by clicking the button like area on the combobox. I move the mouse in the list area, and the area scrolls up and down without selecting something (as expected), if I press [Cursor up] or [cursor down] the marker defining the selected item moves up and down. Clicking an item selects the item.

I have akwardnes with combos in grids, but you use the combo outside a grid, right?

Can you give more information about the combo? RowSourceTyp, how do you create the data, the like?

There is some code in Keypress dealing with [Backspace] on empty combo (do not focus previous element) and [CTRL+0] (do not allow .NULL. entry), but nothing more
LPARAMETERS;
 tnKeyCode,;
 tnShiftAltCtrl

DO CASE
 CASE THIS.SELSTART=0 AND tnKeyCode=127
  NODEFAULT
 CASE THIS.glAllow_Null_Input
 CASE tnShiftAltCtrl=2 AND tnKeyCode=48
  NODEFAULT
ENDCASE
>Error:
>If combobox (style=2 dropdownlist) had more elements and scrollable area, the mouse element selection did not work properly. Same with up and down arrow keys. It was 4 years ago, move from vfp6 to 9, hundreds computers with win 7 to 10.
>From internet I put in MouseUp event of my base combo class:
>LPARAMETERS nButton, nShift, nXCoord, nYCoord
>inkey(.1)
>
>
>>After upgrade from VFP6 to 9 I have problems with comboboxes with more elements.
>>Somebody (thanks again) help me with:
>>inkey(.1)
>>in MouseUp() event
>
>I'm not really sure what you are talking about. Can you give a larger code snippet and a more precise description of the error.
>- what is the goal of the code
>- what is the problem now
>
>Anyway, the use of INKEY() is depreciated in OOP from the start. There is the KeyPress event, and using INKEY will mess it up.
Words are given to man to enable him to conceal his true feelings.
Charles Maurice de Talleyrand-Périgord

Weeks of programming can save you hours of planning.

Off

There is no place like [::1]
Previous
Reply
Map
View

Click here to load this message in the networking platform