APEXblog.nl - Tips and Tricks

About This Blog:
I (Richard Weug) started this blog primary for myself to save all kinds of Apex tips and tricks in one place. To use it as a place to write down how I used some coding in my own projects, but also to copy and paste all kinds of articles I find on the Internet. (So I never have to wonder on what website did I read about??? When I see something interesting I collect the content so I have my own archive/knowlegde base.

View my profile on LinkedIn

 

Tips & Tricks

Print
04
Feb

Manage your LOVs in PL/SQL

Written by Richard Weug on Monday, 04 February 2013 14:16. Posted in Tips and Tricks

Oracle APEX offers an easy to use, yet effective way to control the list of values (LOVs) within your application. This module, which can be found under shared components, enables you to create two different types of LOVs: static and dynamic. Reusability and maintainability are the key principles here: “create once, use many times“. However, I always feel like there is one single shortcoming every time I work intensively with LOVs: The inability to parameterize.

Print
22
Jan

Getting and setting Apex page item values using $v(), $s(), $v2()

Written by Richard Weug on Tuesday, 22 January 2013 14:43. Posted in Tips and Tricks

The Apex JavaScript API has some very convenient functions to access the values of page items.For example, if you wante to access the contents of a text field with JavaScript, would would need to reference it something like this:

Print
03
Jan

Refreshing a tabular form

Written by Richard Weug on Thursday, 03 January 2013 14:14. Posted in Tips and Tricks

Today I encountered some difficulties refreshing a tabular form without submitting the entire page. The data displayed in my tabular form depends on the value of a select list (nothing more than a parent-child relation). If you don’t know where I am talking about, please check out following example.

Print
13
Sep

PDF Creation with direct print dialog

Written by Richard Weug on Thursday, 13 September 2012 09:10. Posted in Tips and Tricks

This solution is based on the usage of Jasper Reports to create PDF reports inside APEX.

You may had the requirement to create a PDF document with a direct print dialog but there should be no download pop-up dialog or an in-line view appear where the end user explicitly needed to click on the print button. Seems to be a simple problem: Print dialog should immediately appear after PDF creation.

Actualy there is a quite easy workaround available:
Just add this new property under the properties section (for you document) in the iReport builder settings.

/* Property name */
net.sf.jasperreports.export.pdf.javascript
/* Property value */
this.print({bUI: true,bSilent: true,bShrinkToFit: false});

Print
29
May

Flashback

Written by Richard Weug on Tuesday, 29 May 2012 09:40. Posted in Tips and Tricks

The Flashback Query feature of Oracle (10g) can be really helpful when you run that UPDATE or DELETE statement and then, after the COMMIT, you discover that you made a mistake!

Wouldn't it be nice to be able to look back and see what the data looked like before you messed things up? With a Flashback Query you can do just that: