Home » Developer & Programmer » Forms » pre-text-item (form 6i,xp)
pre-text-item [message #359672] Mon, 17 November 2008 23:47 Go to next message
sinida1984
Messages: 83
Registered: September 2007
Location: India
Member
Hi

In my form, for an item there is code for pre-text-item trigger. In query mode when i go to next record, previous record etc, whether this trigger gets fired? In other forms it is getting executed. Only in this form it is not getting executed. What should be reason for not executing this pre-text-item? Only this item is enabled and cursor is there. If you have any idea, pease help me.

Regards
Sinida
Re: pre-text-item [message #359696 is a reply to message #359672] Tue, 18 November 2008 00:52 Go to previous messageGo to next message
djmartin
Messages: 10180
Registered: March 2005
Location: Canberra ACT Australia
Senior Member
Account Moderator
Verify the properties of this trigger and verify that it has 'Fire in enter query mode' set to 'yes'.

David
Re: pre-text-item [message #359704 is a reply to message #359696] Tue, 18 November 2008 00:58 Go to previous messageGo to next message
sinida1984
Messages: 83
Registered: September 2007
Location: India
Member
Hi

I checked the properties also. All those were correct. Fire in enter query mode was 'Yes' only. Now I deleted the trigger. Created a new one with the same properties and code. Now it is executing. Don't know what magic. May be some problem.

Anyway thank you for your quick and valuable reply.

Regards
Sinida
Re: pre-text-item [message #359940 is a reply to message #359704] Tue, 18 November 2008 22:46 Go to previous messageGo to next message
djmartin
Messages: 10180
Registered: March 2005
Location: Canberra ACT Australia
Senior Member
Account Moderator
Maybe your needed to do a Ctrl-Shft-K (Compile All). Maybe you had an old copy of the executable in another browser when you regenerated the form and reran it.

David
Re: pre-text-item [message #523362 is a reply to message #359704] Sat, 17 September 2011 01:56 Go to previous messageGo to next message
m3nhaq
Messages: 20
Registered: September 2011
Location: Pakistan
Junior Member
Hi... I stuck in the same problem, I delete the trigger and make new one but the prblem is not solve.

I have three text item
1. TRANSACTED_AMOUNT
2. YIELD
3. PRICE

I want to change value of TRANSACTED_AMOUNT
by formula

Here is the Function:

FUNCTION Calc_Sattlement_Amount RETURN number IS
v_sett_price fis_contract.price%type;
begin

v_sett_price := ROUND((:record_block.face_value/100 * :record_block.price), 4);
return to_number(v_sett_price);

end;

and Here is the pre-text-item trigger

begin
:record_block.transacted_amount := Calc_Sattlement_Amount;

end;

I use the above code with both pre-text-item and post-text-item trigger


Kindly reply....

[Updated on: Wed, 21 September 2011 08:24] by Moderator

Report message to a moderator

Re: pre-text-item [message #523367 is a reply to message #523362] Sat, 17 September 2011 04:07 Go to previous messageGo to next message
ranamirfan
Messages: 529
Registered: January 2006
Location: Pakistan / Saudi Arabia
Senior Member

Please read the Forum Guides before posting.
This thread is very old.

Try it POST-CHANGE Trigger at Block Level.
Begin
:record_block.transacted_amount := Calc_Sattlement_Amount;
End;




Regards,
Irfan
Re: pre-text-item [message #523371 is a reply to message #523367] Sat, 17 September 2011 05:00 Go to previous messageGo to next message
m3nhaq
Messages: 20
Registered: September 2011
Location: Pakistan
Junior Member
Dear Irfan thanks for reply....

I apply trigger at block level, and it calculate values and display as I save the form.

But, I need to apply trigger to show calculate value as any value is changed in fields.
Re: pre-text-item [message #523372 is a reply to message #523367] Sat, 17 September 2011 05:10 Go to previous messageGo to next message
m3nhaq
Messages: 20
Registered: September 2011
Location: Pakistan
Junior Member
"Please read the Forum Guides before posting.
This thread is very old."

Kindly tell me the link of Forum Guides. I am new user.
Re: pre-text-item [message #523373 is a reply to message #523372] Sat, 17 September 2011 05:19 Go to previous messageGo to next message
cookiemonster
Messages: 12422
Registered: September 2008
Location: Rainy Manchester
Senior Member
forum guide

Post-change is an obsolete trigger. Use When-validate-item on face_value and price.
Re: pre-text-item [message #523908 is a reply to message #523373] Wed, 21 September 2011 01:38 Go to previous message
m3nhaq
Messages: 20
Registered: September 2011
Location: Pakistan
Junior Member
Thank you all for helping..

I figure out the problem.

The problem was, I wanted to apply POST-TEXT-ITEM trigger on calculation, but it wasn`t working.

I solve it by changing the form property palette -> Data Base -> Validation unit = item

Now POST-TEXT-ITEM trigger works.

[Updated on: Wed, 21 September 2011 08:25] by Moderator

Report message to a moderator

Previous Topic: PARAMETRIC CURSOR EXAMPLE WITH FMB
Next Topic: Make Field protected against update
Goto Forum:
  


Current Time: Fri Dec 09 19:39:57 CST 2016

Total time taken to generate the page: 0.12108 seconds