Solved

FORMS 9i- help with SET_ITEM_PROPERTY

Posted on 2006-11-09
3
1,847 Views
Last Modified: 2008-01-16
I have a field on my form as a TEXT ITEM and the properties are ENABLED YES, VISIBLE NO.

WHen I start the form the field is hidden just as I want it to be. But when I run some code, it shoudl become VISIBLE, but its not.

My code is

IF :acctount > 0 then
    set_item_property('TXT_AMOUNT',enabled,property_true);
    set_item_property ('TXT_AMOUNT',visible, property_true);
end if;

0
Comment
Question by:joekeri
3 Comments
 
LVL 6

Accepted Solution

by:
Ritesh_Garg earned 35 total points
ID: 17912178
First thing is check if this piece of code is really executing.
Put some message and use pause;
Also before you run / create fmx, use ctl+shift+k so that the form compiles completely.

If you are sure that these above are not the reason, try using synchronize;
E.g.

IF :acctount > 0 then
    set_item_property('TXT_AMOUNT',enabled,property_true);
    set_item_property ('TXT_AMOUNT',visible, property_true);
end if;
Synchronize;


Thanks,
Ritesh
0
 
LVL 12

Expert Comment

by:jwahl
ID: 17912312
also make sure that the item is on the correct canvas, tab page etc.
check the position of the item in the layout editor.
you can also check if the trigger is executed correctly with some extra checks (e.g. in an WHEN-MOUSE-DOUBLECLICK trigger);

BEGIN
    IF GET_ITEM_PROPERTY('TXT_AMOUNT',visible) = 'TRUE' THEN
        MESSAGE('Item is visible at ' || GET_ITEM_PROPERTY('TXT_AMOUNT', x_pos) || '/' || GET_ITEM_PROPERTY('TXT_AMOUNT', y_pos));pause;
    ELSE
        MESSAGE('Item is NOT visible!');PAUSE;
    END IF;
END;
0
 
LVL 28

Expert Comment

by:Naveen Kumar
ID: 17913032
yes, try synchronize; once to see whether it is an issue related to memory/canvas refresh.

Thanks
0

Featured Post

Secure Your Active Directory - April 20, 2017

Active Directory plays a critical role in your company’s IT infrastructure and keeping it secure in today’s hacker-infested world is a must.
Microsoft published 300+ pages of guidance, but who has the time, money, and resources to implement? Register now to find an easier way.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
dbms_crypto.decrypt   errors out 6 43
make null the repeated levels 2 37
sum of columns in a row in oracle 3 42
DECLARATION OF CURSOR IS INCOMPLETE OR MALFORMED 5 40
Background In several of the companies I have worked for, I noticed that corporate reporting is off loaded from the production database and done mainly on a clone database which needs to be kept up to date daily by various means, be it a logical…
This post first appeared at Oracleinaction  (http://oracleinaction.com/undo-and-redo-in-oracle/)by Anju Garg (Myself). I  will demonstrate that undo for DML’s is stored both in undo tablespace and online redo logs. Then, we will analyze the reaso…
This video explains at a high level with the mandatory Oracle Memory processes are as well as touching on some of the more common optional ones.
Via a live example, show how to take different types of Oracle backups using RMAN.

756 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question