[AccessD] Filter records in a list via a combo

Stuart McLachlan stuart at lexacorp.com.pg
Sat May 1 18:50:52 CDT 2004


On 1 May 2004 at 20:33, Kostas Konstantinidis wrote:

> Hi Brett,
> may be I didn't manage to explain what I exactly want to do.
> Well, Into a form there are: a text box (txt_names) and a list box
> (list_names)
> The main table MT_basic_char in which there is the Last_name (about 3
> thousand names) is the source of the asking data
> 
> When I put the event
> Private Sub txt_names_Change()
> Me![list_names].RowSource = "SELECT [Last_Name] FROM [MT_basic_char] WHERE
> [Last_Name] like '" & Me![txt_names].Text & "'"
> End Sub
> 
> and begin to write with e.g. the letters kos it should answer with all the
> records beginning with "kos" etc etc
> 
> Instead of that in the list I see only  ==> SELECT [Last_Name] FROM
> [MT_basic_char] WHERE [Last_Name] like 'kos'
> 
> Am I doing something wrong?
> 
Set the RowSourceType of list_names to "Table/Query". It must be 
currently set to "Value List".

 
-- 
Lexacorp Ltd
http://www.lexacorp.com.pg
Information Technology Consultancy, Software Development,System 
Support.






More information about the AccessD mailing list