Show Duplicate records once enterd

Firefly

Registered User.
Local time
Today, 14:39
Joined
Jun 4, 2007
Messages
11
Okay i have the following in a combo box called cmbzip on a form call frmMember

SELECT tblCityStateZip.Zip, tblCityStateZip.City, tblCityStateZip.State
FROM tblCityStateZip;

In the after update event i have the following

Private Sub cmbZip_AfterUpdate()
Me.txtCity = Me.cmbZip.Column(1)
Me.txtState = Me.cmbZip.Column(2)
End Sub


I also have another form called frmZipcodeSearch which has a listbox called list0 with the following

SELECT tblCityStateZip.City, tblCityStateZip.State, tblCityStateZip.Zip
FROM tblCityStateZip;


let say i have 2 cities associated with the same zipcode

Los Angeles 91105
Pasadena 91105


What i want to do is if a user enters the zip code on the frmmembers and there is another city associated with that zip code the frmzipcodesearch will
pop up displaying those records in the list box.

Any ideas.
 
Okay i have the following in a combo box called cmbzip on a form call frmMember

SELECT tblCityStateZip.Zip, tblCityStateZip.City, tblCityStateZip.State
FROM tblCityStateZip;

In the after update event i have the following

Private Sub cmbZip_AfterUpdate()
Me.txtCity = Me.cmbZip.Column(1)
Me.txtState = Me.cmbZip.Column(2)
End Sub


I also have another form called frmZipcodeSearch which has a listbox called list0 with the following

SELECT tblCityStateZip.City, tblCityStateZip.State, tblCityStateZip.Zip
FROM tblCityStateZip;


let say i have 2 cities associated with the same zipcode

Los Angeles 91105
Pasadena 91105


What i want to do is if a user enters the zip code on the frmmembers and there is another city associated with that zip code the frmzipcodesearch will
pop up displaying those records in the list box.

Any ideas.

Hey FireFly,

My first thought would be to use OpenArgs in frmzipcodesearch OnLoad event to dynamically load the rowsource for list0 and then be sure to add WHERE to your SQL statement and have tblCityStateZip.Zip in the list0 = tblCityStateZip.Zip on frmMember. Hope this makes sense.

HTH,
Shane
 

Users who are viewing this thread

Back
Top Bottom