Disable Or Enable Parameter Form [message #304555] |
Wed, 05 March 2008 11:29 |
gnod
Messages: 19 Registered: December 2007
|
Junior Member |
|
|
Hi,
I have 4 Parameters (From Invoice, To Invoice, Code, Port).
If the user input a data in "From invoice" and "To Invoice", the "Code" will be disable but if the "Code" has a data the "From Invoice" and "To Invoice" will be disable.
the "Port" is always enable..
How do I disable or enable? if ever, can someone else provide a sample file? I'm only a newbie in Report6i
Thanks..
|
|
|
Re: Disable Or Enable Parameter Form [message #304668 is a reply to message #304555] |
Thu, 06 March 2008 01:23 |
|
Littlefoot
Messages: 21823 Registered: June 2005 Location: Croatia, Europe
|
Senior Member Account Moderator |
|
|
As far as I can tell, no way in Reports.
However, two workarounds come to my mind at the moment: create your own "parameter form" using the Forms Builder and, depending on conditions you've mentioned, enable or disable desired form items.
Another way doesn't require Forms; create additional set of parameters - for every "real" parameter, which will appear on the parameter form, create its pair. In the AFTER-PARAMETER-FORM trigger, depending on values user has entered, calculate which "pair parameters" will be set to what values. In a report query, you'd then use these "pair" parameters instead of the ones user sees on the parameter form.
|
|
|
|
|
Re: Disable Or Enable Parameter Form [message #304843 is a reply to message #304555] |
Thu, 06 March 2008 22:01 |
gnod
Messages: 19 Registered: December 2007
|
Junior Member |
|
|
how do i modify my sql using this condition in the where clause?
if :p_awbcode is null, it will execute the :pinv_from and :p_inv_to.. if :pinv_from and :p_inv_to is null, it will execute :p_awbcode
WHERE inv.comp_code = 'AATC' AND invd.comp_code = 'AATC'
AND inv.port_code = :p_port
AND (awb.code = :p_awbcode
OR (SUBSTR (inv.invoice_no, 4) BETWEEN SUBSTR (:p_inv_from, 4)
AND SUBSTR (:p_inv_to, 4)
AND SUBSTR (inv.invoice_no, 1, 3) = SUBSTR (:p_inv_to, 1, 3)))
thanks.
|
|
|
|
Re: Disable Or Enable Parameter Form [message #304946 is a reply to message #304868] |
Fri, 07 March 2008 05:00 |
gnod
Messages: 19 Registered: December 2007
|
Junior Member |
|
|
thanks..
i already solve the script
AND awb.code = NVL (:p_awbcode, awb.code)
AND SUBSTR (inv.invoice_no, 4) BETWEEN SUBSTR (NVL (:p_inv_from, inv.invoice_no), 4)
AND SUBSTR (NVL (:p_inv_to, inv.invoice_no), 4)
AND SUBSTR (inv.invoice_no, 1, 3) = SUBSTR (NVL (:p_inv_to, inv.invoice_no), 1, 3)
|
|
|