Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Parameter Forms
Message
De
05/10/2000 08:19:02
Mike Davis
Per-Se Technologies
Elgin, Illinois, États-Unis
 
 
À
04/10/2000 05:17:52
Rachel Bray
Cornwall County Council
Truro, Royaume Uni
Information générale
Forum:
Microsoft Office
Catégorie:
Access
Titre:
Divers
Thread ID:
00424590
Message ID:
00425223
Vues:
18
Rachel,

If you have a form built already to display information, why not use it with a command that searches all the fields and builds the criteria needed. ie Name:txtName
City:txtCity
St :txtState
You need a clear command to clear all the fields and a search command button.
sub cmdSearch_click()
dim s as string

if not isEmpty(txtName) then s="Name like ' & trim(txtName) & "'"
if not isEmpty(txtCity) then
if not isEmpty(s) then s=s & " And "
s=s & s="City like ' & trim(txtCity) & "'"

...
if not isEmpty(s) then s=" Where " & s
end sub

Otherwise you have to populate a list of fields and add functionality for multiple selections.

hth MikeD
btw
public Function isEmpty(anyString as string) as boolean

if trim(s)=vbNullString then
isEmpty=True
endif
end function
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform