Re: Persistant variable in Form 6i

From: Richard Senior <richard_at_r-senior.demon.co.uk>
Date: 8 Aug 2001 08:24:27 GMT
Message-ID: <9kqsvr$tv$1_at_gate.local>


[Quoted] In article <997220476.23880.0.pluto.d4ee154e_at_news.demon.nl>,

        "Sybrand Bakker" <postbus_at_sybrandb.demon.nl> writes:
>
> "CupOfWater" <asiandoof_at_hotmail.com> wrote in message
> news:e0c9495d.0108071309.70b1e7e3_at_posting.google.com...
 

[Quoted] >> wouldn't want the message to come up every single time.  Is there a
>> way to create a persistance variable - a flag essentially that will
>> last for the execution of the form?

>
> Create a package with a variable defined in the package specification.

Another way is to use a global variable in the form. These only allow you to store character data up to 255 characters but they are visible across all triggers in your form (in fact they are visible across different modules in your runtime session too). There's no need to declare them, just assign a value:

:GLOBAL.message_displayed := 'TRUE';

You might also find the DEFAULT_VALUE builtin useful for giving global variables a value if they are null, e.g.

DEFAULT_VALUE('FALSE', 'GLOBAL.message_displayed');

-- 
Regards,

Richard Senior
Mill Dam Consulting Ltd, London
Oracle Consulting & Training
Received on Wed Aug 08 2001 - 10:24:27 CEST

Original text of this message