Hello,
When the user presses a character to move to the item within a COMBOBOX, it does not work. I updated to version 7.01.
Combobox Problem
I noticed that too.
To solve it for the moment, I linked in the COMBOBOX.PRG from FW 2.7.
Now it's working fine.
Regards,
Michel
To solve it for the moment, I linked in the COMBOBOX.PRG from FW 2.7.
Now it's working fine.
Regards,
Michel
Regards,
Michel D.
Genk (Belgium)
_____________________________________________________________________________________________
I use : FiveWin for (x)Harbour v. 21.01 - Harbour 3.2.0 (October 2020) - xHarbour Builder (January 2020) - Bcc7
Michel D.
Genk (Belgium)
_____________________________________________________________________________________________
I use : FiveWin for (x)Harbour v. 21.01 - Harbour 3.2.0 (October 2020) - xHarbour Builder (January 2020) - Bcc7
No problem.
Here it is.
Just copy and paste and you've got is.
Michel
*edited by admin*
Here it is.
Just copy and paste and you've got is.
Michel
*edited by admin*
Regards,
Michel D.
Genk (Belgium)
_____________________________________________________________________________________________
I use : FiveWin for (x)Harbour v. 21.01 - Harbour 3.2.0 (October 2020) - xHarbour Builder (January 2020) - Bcc7
Michel D.
Genk (Belgium)
_____________________________________________________________________________________________
I use : FiveWin for (x)Harbour v. 21.01 - Harbour 3.2.0 (October 2020) - xHarbour Builder (January 2020) - Bcc7
Re: Combobox Problem
Yes, confirm!cdmmaui wrote:When the user presses a character to move to the item within a COMBOBOX, it does not work. I updated to version 7.01.
for solve, replace the method KeyChar with this:
Code: Select all
//----------------------------------------------------------------------------//
METHOD KeyChar( nKey, nFlags ) CLASS TComboBox
local nNewAT := 0, nOldAT := ::nAT, uItem
do case
case nKey = 32 // VK_DELETE (DO NOT WORK!)
::cSearchKey := ""
nNewAt := 1
uItem := ::aItems[nNewAt]
case nKey = VK_BACK
::cSearchKey := Left( ::cSearchKey, Len( ::cSearchKey ) - 1 )
case nKey = 190
nKey := 0
::cSearchKey += "."
otherwise
::cSearchKey += Upper( Chr( nKey ) )
endcase
if Empty( uItem )
if nNewAt == 0
nNewAt := AScan( ::aItems, {|x| Upper(x) = ::cSearchKey } )
IF nNewAt > 0 .AND. Len( ::aItems ) <= nNewAt
uItem := ::aItems[ nNewAt ]
ENDIF
uItem := ::aItems[ IIF( nNewAt > 0, nNewAt, Max( ::nAT, 1 ) ) ]
else
uItem := ::aItems[ Max( nNewAt, 1) ]
endif
endif
::Set( uItem )
if ::bChange != nil .and. ( nNewAT != nOldAt .and. nNewAt != 0 )
Eval( ::bChange, Self, ::varGet() )
endif
if nKey == VK_RETURN
return ::oWnd:GoNextCtrl( ::hWnd )
endif
return 0 // Must be 0 - We don't want API default behavior.
Ciao, best regards,
Ugo
Ugo
- Antonio Linares
- Site Admin
- Posts: 37481
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Contact: