Hi, I have no room on my form for a list box, so I've used a combo box instead. An SQL query creates a cursor that I then use as the data source. What I really want is for the user to type the first character of a stock code they are looking for into the combo box. This should open the combo box, displaying all stock codes starting with that letter. Each time they type in a further character, I want to further filter the data source so that they end up with a group of stock codes they can make a final selection from.
I can't get the combo box to open and display all entries after they've typed in the first search letter (This is important). Subsequently, I tried using the following code in the keyPress method for the filter (but it only works for 1 character)
private m.lookup
store upper(chr(nKeyCode)) to m.lookup
select c_stock
set filter to left(c_stock.stock_code,1) == alltrim(m.lookup)
Any ideas/code anyone ?
Jim Worley
jim@aits-uk.net
15 years practical IT experience from sales to support to development plus B.Sc. (Hons) Computer Studies, fluent German speaker, willing to have a go at anything and don't suffer fools gladly !
I can't get the combo box to open and display all entries after they've typed in the first search letter (This is important). Subsequently, I tried using the following code in the keyPress method for the filter (but it only works for 1 character)
private m.lookup
store upper(chr(nKeyCode)) to m.lookup
select c_stock
set filter to left(c_stock.stock_code,1) == alltrim(m.lookup)
Any ideas/code anyone ?
Jim Worley
jim@aits-uk.net
15 years practical IT experience from sales to support to development plus B.Sc. (Hons) Computer Studies, fluent German speaker, willing to have a go at anything and don't suffer fools gladly !