• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 10071
  • Last Modified:

Oracle Forms 6i List of Values

Hello Experts,

Can you please advise me on this:

I have a form [6i]with 'Tabs'.
I have a LOV in tab 'region'.user invokes the LOV and selects a value from it and saves the record.It works fine. If the user does not select the value from LOV by clicking 'Cancel'
then I retrieve the existing value by using get_item_property.when i click on second tab 'sales' and come back to tab 'region' forms prompts 'Do you want to save changes you have made'.I have  not made any change.How can I suppress 'Do you want to save changes'??
if :region.reason = 1 then


      DECLARE
             dummy       BOOLEAN;
      BEGIN

          dummy := Show_LOV('constraints',460,130);
          IF NOT DUMMY then
          :region.onreason := get_item_property('region.onreason',database_value);
          
                      raise form_trigger_failure;
          end if;
             END;


 end if;

Thanks
if :region.reason = 1 then
 
 
	DECLARE
		 dummy	 BOOLEAN;
	BEGIN
 
    	dummy := Show_LOV('constraints',460,130);
    	IF NOT DUMMY then
    	:region.onreason := get_item_property('region.onreason',database_value);
    	
    			raise form_trigger_failure;
    	end if;
		 END; 
 
 
 end if;

Open in new window

0
spsun
Asked:
spsun
  • 2
2 Solutions
 
Ritesh_GargCommented:
Try this:
DECLARE
   dummy          BOOLEAN;
   l_rec_status   varchar2(10);
BEGIN
   l_rec_status := get_record_property(to_number(:system.cursor_record),:system.current_block, status);
   dummy := Show_LOV('constraints',460,130);
   IF NOT DUMMY then
     :region.onreason := get_item_property('region.onreason',database_value);
     raise form_trigger_failure;
   end if;
  set_record_property(:system.cursor_record),:system.current_block, status, l_rec_status);
END; 

Open in new window

0
 
Ritesh_GargCommented:
A correction:
DECLARE
   dummy          BOOLEAN;
   l_rec_status   varchar2(10);
BEGIN
   l_rec_status := get_record_property(to_number(:system.cursor_record),:system.current_block, status);
   dummy := Show_LOV('constraints',460,130);
   IF NOT DUMMY then
     :region.onreason := get_item_property('region.onreason',database_value);
     set_record_property(:system.cursor_record),:system.current_block, status, l_rec_status);
     raise form_trigger_failure;
   end if;
END; 

Open in new window

0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Cloud Class® Course: SQL Server Core 2016

This course will introduce you to SQL Server Core 2016, as well as teach you about SSMS, data tools, installation, server configuration, using Management Studio, and writing and executing queries.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now