Home » Developer & Programmer » Forms » When Check Box Changed (Forms 6i)
When Check Box Changed [message #405885] Sun, 31 May 2009 01:35 Go to next message
arif_md2009
Messages: 732
Registered: May 2009
Location: United Arab Emirates
Senior Member

Hi All,

I have created a form based on three tables and the functionality of the form is i need to choose the location code and batch it will populate the list of items available in that location and batch area and then after viewing this item i press a button to create a transaction which is done now.But the problem is i need to attach check box along with items so that i can select the item by clicking on checkbox and inserting those items which are checked.Please refer attachment.
  • Attachment: OPM0015.fmb
    (Size: 776.00KB, Downloaded 1174 times)
Re: When Check Box Changed [message #405965 is a reply to message #405885] Mon, 01 June 2009 03:24 Go to previous messageGo to next message
arif_md2009
Messages: 732
Registered: May 2009
Location: United Arab Emirates
Senior Member

arif_md2009 wrote on Sun, 31 May 2009 01:35
Hi All,

I have created a form based on three tables and the functionality of the form is i need to choose the location code and batch it will populate the list of items available in that location and batch area and then after viewing this item i press a button to create a transaction which is done now.But the problem is i need to attach check box along with items so that i can select the item by clicking on checkbox and inserting those items which are checked.Please refer attachment.

Re: When Check Box Changed [message #406011 is a reply to message #405965] Mon, 01 June 2009 10:59 Go to previous messageGo to next message
klat
Messages: 87
Registered: May 2009
Location: Mumbai
Member

Hi,

You can add a checkbox(example: is_selected) with in the same block where your items are displayed.

while inserting record
if is_selected = 'Y' then
  insert_record;
end if;


it will insert only the selected records.
Re: When Check Box Changed [message #406063 is a reply to message #406011] Tue, 02 June 2009 00:29 Go to previous messageGo to next message
arif_md2009
Messages: 732
Registered: May 2009
Location: United Arab Emirates
Senior Member

thanks klat but i am actually using one proceedure to insert those records.Actually i have 2 tables one is ot_adj_head and the other is ot_adj_item and i am inserting into these tables but i dont know how to implement the logic of selection.Can u just look in to my form as i m not able to move forward.
Re: When Check Box Changed [message #406165 is a reply to message #406063] Tue, 02 June 2009 10:51 Go to previous messageGo to next message
klat
Messages: 87
Registered: May 2009
Location: Mumbai
Member

Attach your pl/sql library and object library.
what you have to do is add one checkbox(non database) in your detail block. I hope that your detail block is a data block.

with in the On-insert trigger

if :is_selected = 'Y' then
insert_record;
end if;

It will insert only selected records.

if you are using separate procedure to insert data , then
check in that procedure


go_block('details');

loop
 if :is_selected = 'Y' then
   insert into ....
 end if;
 
 if :system.last_record = 'TRUE' then
  exit;
 else
  next_record;
 end if;

end loop;

commit;




Re: When Check Box Changed [message #406733 is a reply to message #406165] Fri, 05 June 2009 09:40 Go to previous messageGo to next message
klat
Messages: 87
Registered: May 2009
Location: Mumbai
Member

have you solved your issue??

Re: When Check Box Changed [message #406805 is a reply to message #406733] Sat, 06 June 2009 00:26 Go to previous message
arif_md2009
Messages: 732
Registered: May 2009
Location: United Arab Emirates
Senior Member

thanks klat for your concern.I am working on this issue.Well what i am doing is using your logic i am first inserting data into temporary table when the check box is checked and then upon pressing the button i am inserting again to real tables.
Previous Topic: Forms 9i: Trying to run report: FRM-41214
Next Topic: how to use LOV (split calling report from oracel form)
Goto Forum:
  


Current Time: Fri Sep 20 12:50:42 CDT 2024