Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Executing a trigger using code?

Posted on 2001-08-09
7
Medium Priority
?
2,264 Views
Last Modified: 2007-12-19
I have an Edit button, and I want to execute the WHEN-BUTTON-PRESSED trigger from another object on the screen.  Is that a command that will enable me to run that trigger?

To be more precise, I have a textbox on the screen, and when the user double-clicks the textbox, I want to run the code in the button's WHEN-BUTTON-PRESSED trigger.

Thanks,
Brian
0
Comment
Question by:bek
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
7 Comments
 
LVL 3

Expert Comment

by:p_yaroslav
ID: 6368284
Hello!

May br better create event ON-DOUBLE-CLICK???

Yaroslav.
0
 
LVL 35

Expert Comment

by:Mark Geerlings
ID: 6368380
Move the code you want executed from the when-button-pressed trigger to a new program_unit in the form.  Then from the when-button-pressed trigger simply run the program_unit.  Also, create a when-mouse-double-click trigger in that text item that runs the same program unit.
0
 
LVL 48

Expert Comment

by:schwertner
ID: 6368413
Use EXECUTE_TRIGGER built-in to execute that trigger in When-Mouse-DoubleClick Trigger.

A better solution is to embed the code invoking the editor in a program unit belonging to the form and invoking this program unit (procedure) in both places.
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 2

Accepted Solution

by:
santoshmathew earned 200 total points
ID: 6368621
Hi,

You can use the built in Execute_trigger('Tigger-name') to do this.

You can write  Execute_trigger(When-Button-Pressed');

in another trigger/Program Unit to execute the When-Button-Pressed trigger.

Cheers.
0
 
LVL 2

Expert Comment

by:santoshmathew
ID: 6368634
Sorry, looks like Schwertner and I was typing were typing at the same time.
0
 

Author Comment

by:bek
ID: 6368752
I took markgeer's advice and put the code in a program unit.  How do I run a program unit?

(Thanks for the help, guys.  I guess it's obvious I'm new to Oracle.)
0
 

Author Comment

by:bek
ID: 6368794
Thanks to everyone.  I awarded the points to the answer that seemed the most straightforward (santoshmathew), but I appreciate everyone's response!

I am getting ready to ask another question about an Oracle trigger I can't seem to find.  It's the equivalent of Microsoft's "Interactive Change Event", for those of you with VB experience.  Watch for my question, coming up immediately!

Thanks,
Brian
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Note: this article covers simple compression. Oracle introduced in version 11g release 2 a new feature called Advanced Compression which is not covered here. General principle of Oracle compression Oracle compression is a way of reducing the d…
Shell script to create broker configuration file using current broker Configuration, solely for purpose of backup on Linux. Script may need to be modified depending on OS-installation. Please deploy and verify the script in a test environment.
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Via a live example, show how to restore a database from backup after a simulated disk failure using RMAN.

721 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