M
Martin
Hi! According to the following VBA (written by Dirk), I have two
questions:
1.What's the meaning of Chr(34) ?
2.If later (for example when I get out off this function), I want to make
the filter unavailable(that is, show all the records), How should I write
the VBA sentence?
3. is this OK? -- DoCmd.ApplyFilter , "[customer name]=Martin Lee" ??
-- DoCmd.ApplyFilter , "[customer name]"="Martin Lee" ??
Thanks. And thanks Dirk.
Dim strCustomerWanted As String
strCustomerWanted = "Martin Lee"
Docmd.OpenTable "Customer Inf"
DoCmd.ApplyFilter , "[customer name]=" & _
Chr(34) & strCustomerWanted & Chr(34)
questions:
1.What's the meaning of Chr(34) ?
2.If later (for example when I get out off this function), I want to make
the filter unavailable(that is, show all the records), How should I write
the VBA sentence?
3. is this OK? -- DoCmd.ApplyFilter , "[customer name]=Martin Lee" ??
-- DoCmd.ApplyFilter , "[customer name]"="Martin Lee" ??
Thanks. And thanks Dirk.

Dim strCustomerWanted As String
strCustomerWanted = "Martin Lee"
Docmd.OpenTable "Customer Inf"
DoCmd.ApplyFilter , "[customer name]=" & _
Chr(34) & strCustomerWanted & Chr(34)