Re: Dev 2000 Forms ? part 2

From: Steve Cosner <stevec_at_zimmer.CSUFresno.EDU>
Date: 1996/09/13
Message-ID: <51c3ed$mio_at_zimmer.CSUFresno.EDU>#1/1


In article <51a19p$1rp_at_cougar.cse.psu.edu>, Elizabeth S Boese <boese_at_cse.psu.edu> wrote:

>3) I have a drop down list on the form, and i want to know
> what the value of it is on POST-CHANGE or the similar
> such that when a user changes their choice, I can
> update another drop down list based on that choice.
> i.e.
> choices: US Central Am. Europe
> origianlly the second group of choices based on US
> would be: NY, NJ, PA, CO, UT, TX, etc.
> when the user changes the first drop down box s.t.
> Central Am. is showing, the
> second group of choices would then change to:
>
> Costa Rica, Mexico, Belize, Ecudor, etc.
>
>FIRST Problem: I don't know how to get the value in the
> first drop-down list ( GET_LIST_ELEMENT_VALUE didn't
> work. If this is what i need to use, let me know
> an example and I can try it again.)

Set up a When-Validate-Item trigger in the first item, and in this trigger, set the second item value to itself:

   :blk.second_item := :blk.secon_item; This forces Forms to re-run validation on the second item when you leave the block or commit. Also, depending on the value selected in the first item, change the query of the record group associated with the LOV (on the second item) with a Populate_Group_With_Query function.

On the second item, set up an LOV with the states/countries validation, and be sure to set 'LOV for validation' to true.

Not sure if all this will work, but I believe it should.

Good luck,
Steve Cosner Received on Fri Sep 13 1996 - 00:00:00 CEST

Original text of this message