Re: Passing Parms to Forms 6.0

From: Frans Hovenkamp <Dieze_at_popin.nl>
Date: Tue, 4 Apr 2000 13:36:20 +0200
Message-ID: <8ccjti$j01$1_at_porthos.nl.uu.net>


Christoph Wagner heeft geschreven in bericht <8cc5d4$oj4$1_at_readme.inode.at>...
>Hi
>
>First of all you have to define your params in the form you are calling.
>
>Then write some code like this to call the specific form.
>
>
>DECLARE
> pl_id ParamList;
>BEGIN
> pl_id:=get_parameter_list('p_list');
> -- searches for a PARAM_LIST with the same name
> IF NOT ID_NULL(pl_id) THEN
> -- if found destroy
> DESTROY_PARAMETER_LIST(pl_id);
> END IF;
> -- create new list
> pl_id:=CREATE_PARAMETER_LIST('p_list');
> -- add a parameter named like the parameter in your called form
> ADD_PARAMETERpl_id,<param_name>,TEXT_PARAMETER,<value>);
> -- open the desired form with the parameter information
> OPEN_FORM(<your_form>,ACTIVATE,SESSION,pl_id);
>
> -- watch out !!! Forms will never reach code after open_form
>END;
>
>
>Then move to the called form.
>Create a TRIGGER WHEN-NEW-FORM-INSTANCE and code it like this:
>
>BEGIN
> IF :PARAMETER.<your_param> IS NOT NULL THEN
> go_block(<desired_block>);
> do_key('Execute_query'); -- executes the query automatically
> END IF;
> -- you also can perform a report calling in here or something else you
>want to perform automatically
>END;
>
>Or use the parameter in the WHERE CLAUSE of the called form:

    like : item_name = :parameter

Frans Hovenkamp

>hth Christoph
>---------------
>
><jehall_at_my-deja.com> schrieb in im Newsbeitrag:
>8cau0u$pfd$1_at_nnrp1.deja.com...
>> How do I pass parms to a Oracle Form and use these parms as part of a
>> where clause which will automatically query the information for the
>> user, so that it will run the report with the information already on the
>> screen?????????????? The user, in other words, DOES NOT initially have
>> to do a query enter/query execute on the form. Is there a way?
>>
>> Thanks so much,
>>
>> Jason.
>>
>>
>> Sent via Deja.com http://www.deja.com/
>> Before you buy.
>
>
Received on Tue Apr 04 2000 - 13:36:20 CEST

Original text of this message