Oracle APEX 4.0: How to create a Plug-in

Oracle APEX 4.0: How to create a Plug-in

21. December 2009

Oracle APEX, Plug-ins

As promised on Saturday, I had a look at my existing plug-in tutorials, reworked them a little bit and have uploaded them so that you can try them out. There are in total five different tutorials for the different available plug-in types supported by Oracle Application Express 4.0. I ordered them based on there complexity. I would suggest that you process them in that order.

Plugin-HowTos.zip contains all the necessary files to get you started. If you want to have a look at more plug-ins or just want to try them out, get my Plug-in Sample Application and install it into your APEX 4.0 Early Adopter Workspace. The plug-ins can be found in Shared Components – Plug-ins.

Have fun playing with plug-ins and I’m looking forward to your feedback and enhancement requests ;-)

17 Responses to “Oracle APEX 4.0: How to create a Plug-in”

  1. Peter Raganitsch Says:

    Great Work !

    Plugins are big fun and make millions of new things possible. I’m digging in right away and work on my first plugin.

    Peter

  2. mark stock Says:

    tried the highlight plug-in; was able to create the plug-in, but when i tried to upload the highlight.js file i got:

    ORA-01407: cannot update (”APEX_040000″.”WWV_FLOW_PLUGIN_FILES”.”MIME_TYPE”) to NULL

    Unable to process row of table WWV_FLOW_PLUGIN_FILES.

    any ideas?

  3. mark stock Says:

    … i was using IE 6.0 (client required) — could that be the problem?

  4. Stew Says:

    Dumb question: Does your Plug-in Sample application use all of the plug-in types in the How-To? I’m not sure I know where to look for them when I run it. I mean, I see the Plug-ins menu tab and the two maps are cool, but what about the other plug-in types?

    Thanks,

    Stew

  5. Stew Says:

    Oops, found my answer with just a little looking through the application (Shared Components->Plug-ins) where I can see exactly where you use the plug-ins you wrote the How-tos for!

    Sorry for the dumb (lazy?) question!

    Some very cool stuff happening here! I especially like the Get-Data plug-in! It’s a whole lot easier to write the query for that than to write all the Javascript it usually requires!

  6. Johannes de Jong Says:

    Hi Patrick,

    I get the folowing error mes when installing your demo app:

    ORA-20001: GET_BLOCK Error. ORA-20001: Execution of the statement was unsuccessful.
    ORA-20001: Error creating branch id="860762340250241075"
    ORA-30036: unable to extend segment by 8 in undo tablespace ‘UNDOTBS1′ <pre>begin wwv_flow_api.create_page_branch( p_id=&gt;793704207557714686 + wwv_flow_api.g_id_offset, p_flow_id=&gt; wwv_flow.g_flow_id, p_flow_step_id=&gt; 7, p_branch_action=&gt; ‘P7_BRANCH’, p_branch_point=&gt; ‘AFTER_PROCESSING’, p_branc

    Kind regards

    Johannes

  7. Patrick Wolf Says:

    Thanks for reporting this issue. It has been fixed.

  8. Johannes de Jong Says:

    Hi Patrick,

    Oracle fixed the problem after I raised a a bug in the feedback in http://tryapexnow.com , or was it my post here :)

    Thanks for your fantastic tutorials.

    Johannes

  9. Patrick Wolf Says:

    It was both :-)

    Patrick

  10. Kishore Says:

    Hi Patrick,

    Exploring APEX4.0 has been exciting. Thanks for the good work done in APEX development team.

    I want to highlight a text field based on the color chosen from select list item. I created a select list P1_COLOR with Green, Red, Yellow and text item P1_TEXT. In dynamic action on P1_COLOR, how do I specific value of P1_COLOR for the Color attribute?

    Thanks
    Kishore

  11. Robert Says:

    I tried to create your highlight plugin and use in the sample application but it failed. I believe APEX 4.0 changed after you created it. It did not match step 32 forward. So when I tested it, I got an error. Also step 16 and 20 assigning List values differs too.

  12. Patrick Wolf Says:

    Hi Robert,

    yes some of the names in the How To do not match with the actual UI. That has already been fixed and I will republish the How To when we refresh our EA instance.

    BTW, you can use my plug-in sample application to get a working copy of the Highlight plug-in.

    Regards
    Patrick

  13. Patrick Wolf Says:

    Hi Kishore,

    using the current value from the browser is a little bit more difficult, because the existing dynamic actions use static values of values from the browser. You have two options:
    1) Create 3 dynamic actions on P1_COLOR where you have a condition for each color and use that color as fixed value in your dynamic action to set the color.
    2) Create just one dynamic action and use the Javascript action with the following code:
    apex.jQuery.apex(’#P1_TEXT’).attr(’color’, $v(’P1_COLOR’));

    Regards
    Patrick

  14. Oliver Lemm Says:

    Hello Patrick, i tried to import your plugin_sample_app.sql file into the early adopter release of apex 4.0.
    In the workspace of tryapexnow there comes the error
    “File is not a valid Application Express plug-in export file.”
    I used different charsets to import the file but the error message above always comes at the point when i try to install it.

    Thx so far for your tips.

  15. Oliver Lemm Says:

    Ok i solved the problem, i checked the file and saw that it was no plugin file. The Application works fine.

Trackbacks/Pingbacks

  1. [...] to create an item type based on the jQuery-UI slider widget.  After reading and exploring some of Patrick Wolf’s documentation, it was pretty easy to find out how to go [...]

  2. [...] – Check out the sample application and tips that Patrick Wolf has already created.  Once you’ve installed these and learned the rules, [...]

Leave a Reply