Re: Power Objects help!!!
Date: 1996/02/12
Message-ID: <ericth-1202962202240001_at_204.19.33.128>#1/1
In article <4fbssq$rdv_at_dub-news-svc-3.compuserve.com>, <lin1_at_studsys.mscs.mu.edu> wrote:
> I need to link a table to a pop-up list box to display all the
rows(records)
> of the table. Could anyone tell me how to do it?
Hi Emily, Well, first you would like to bind that controle to the foreign key on your table, then you need to edit the translation property of the popup field. To link it with the other table. The translation property is something like that:
=AT session_name SELECT column_in_the_popup_field, column_that_is_the_key FROM table_that_is_the_link ORDER BY column_that_it's_sorted_by
Let's break it down...
The <AT session_name> is optional, althought you may prefere to use a different session than the one from the main form, to speed up process (see documentation on database session for more explanation why).
The <column_in_the_popup_field> is the column you wish it appear in the popup from the linked table.
The <column_that_is_the_key> is the column that is to be linked with the column assign in the DataSource property of the popup. So that it automatically match when you open the window, make change, etc...
The <table_that_is_the_link> is the linked table that contain all possible entry for that poppup.
The <column_that_it's_sorted_by> is optional, but you might set it to the same column that <column_in_the_popup_field>, since that it would make sence that it's sorted alphabetically (since it's probably the name of something...).
You can also add a WHERE clause to specify any condition, but in your case you don't need any.
Well, that's it, you'r done.
-- _____________________________________________________________________ Eric Therrien Internet: ericth_at_montrealnet.ca Club Informatique Longueuil: http://www.connectmmic.net/users/cil Président du Club Informatique longueuil inc Montreal, PQ _____________________________________________________________________Received on Mon Feb 12 1996 - 00:00:00 CET