Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Allow user to select a record.

Status
Not open for further replies.

Syerston

Programmer
Jun 2, 2001
142
GB
As I come from a Access VBA background I am sort of knew to the world of VB6.

Could someone give me guidance on the best solution to this problem. I have a form where the user enters a street name and number. The system then checks the database and returns a possible list of addresses. The user then selects one of the addresses which populates various parts of the form.

My dilemma is the best way to display the choices to the user. Multiple columns and headers are required and space is limited on the form.
John
 
Hi John

I don't know if this an approppriate solution but I'll go for it any way. After the user has enetered the details launch another form modally which displays a listview control populated during the form load event. On the click event of the listview assign the key value to a public property of the form(ie treat the form as a class) and then unload the form, you will then be able to do form1.AddressID as the next line of code after the form1.show modal. VB will not release this form from memory until you do

set form1 = nothing

which means you can still get at the public property form1.AddressID
I hope this is of some use at least, best of luck

Steve
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top