Home » Developer & Programmer » Forms » Detail block (froms)
Detail block [message #641306] Thu, 13 August 2015 03:19 Go to next message
palpali
Messages: 138
Registered: December 2014
Location: India
Senior Member
Hallo

I have mater-detail blocks. In detail block, when i want to insert new record then the 4 fields are automatically duplicated as above and the 5th field is empty and must be given. (property Required = yes).
When i insert records in first detail block and go to the second block where i unintenstionaly, press F7 key then it will make a new row with 4 fields' value as above it, and the 5th as empty. But i don't want to enter any value in this field and dont want save any records in second block and want to go first block and/or save the newly inserted records.
But, the problem is, i can not go to the other block without giving any value in the 5th field. and in my case, i just want to save the data in the first detail block without saving the record in the second block. and when i press F4, form exit completely.

WNRI in my detail-block
if :system.block_status = 'QUERY' then
 if :system.record_status = 'NEW' then
   duplicate_record;
   set_block_property('blk1', insert_allowed, property_true);
   :blk1.field5 := null;
set_record_property (:system.trigger_record, :system.trigger_block, status, changed_status); 
  end if;
end if;

Please help,how can i do this?

Regards,
Re: Detail block [message #641307 is a reply to message #641306] Thu, 13 August 2015 03:25 Go to previous messageGo to next message
Littlefoot
Messages: 21806
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
So remove that unintentionally created record. There's the "Delete record" button in the toolbar, use it.
Re: Detail block [message #641310 is a reply to message #641307] Thu, 13 August 2015 03:54 Go to previous messageGo to next message
palpali
Messages: 138
Registered: December 2014
Location: India
Senior Member
Hallo LF,

thank you very much for your prompt Response Smile
well, it helps me to some extent, but isn't that the same when i press F8 key?
When i press Delete record Icon above, it delete the unintentionally inserted row, but F8 did not. I have set the block property Delete = NO.
any idea pleae?
Re: Detail block [message #641311 is a reply to message #641310] Thu, 13 August 2015 04:03 Go to previous messageGo to next message
Littlefoot
Messages: 21806
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Quote:

isn't that the same when i press F8 key

No idea; what is F8 mapped to? (Because, over here, F7 = enter query, F8 = execute query. I don't know what your keys do).
Re: Detail block [message #641312 is a reply to message #641311] Thu, 13 August 2015 04:12 Go to previous messageGo to next message
palpali
Messages: 138
Registered: December 2014
Location: India
Senior Member
i am using forms10, and i have F7 to insert new row, F10 = enter query, F11 = execute query.
isn't that the Default Setting of forms? or would it be set by user? which key for what ?

Re: Detail block [message #641315 is a reply to message #641312] Thu, 13 August 2015 04:30 Go to previous messageGo to next message
Littlefoot
Messages: 21806
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
It doesn't really matter, as long as you explain what F8 does.

Key mapping can be set to value different from default (which is what administrators did here, where I work).
Re: Detail block [message #641326 is a reply to message #641315] Thu, 13 August 2015 06:33 Go to previous messageGo to next message
palpali
Messages: 138
Registered: December 2014
Location: India
Senior Member
Thankx alot LF Smile
Re: Detail block [message #641348 is a reply to message #641326] Thu, 13 August 2015 09:00 Go to previous message
CraigB
Messages: 386
Registered: August 2014
Location: Utah, USA
Senior Member
You can use the F6 - Clear Record or Ctrl + Up Arrow - Delete Record function keys to clear/delete the "Unintentional" record.
Previous Topic: FORM DATA
Next Topic: oracle jinitiator version too low mac please install version 1.1.8.2 or higher
Goto Forum:
  


Current Time: Thu Mar 28 09:11:23 CDT 2024