Some of them implement fairly fancy JavaScript and CSS, but there is a simple way to plug in the default tooltip behaviour into your Apex reports.
When you edit your report column attributes, add the following code into the HTML expression.
<span title="#MY_TOOLTIP_COLUMN#">#MY_COLUMN#</span>
These attributes typically have decent help in regard to the sort of coding examples you can apply.
So this setup places the data from the selected column my_tooltip_column, and displays the value in my_column as you'd normally expect.
And is the display from Google Chrome:
Simple but effective - and flexible.
See a variation on this example here.
Thanks for the tip. This helped me alot.
ReplyDeleteSometimes it's just the little things ;-)
ReplyDeleteNice tip. I love simple and useful ideas without tons of scripts and workarounds. Thanks!
ReplyDeleteThank you very much for this very useful tip.
ReplyDeleteSteffy
Do you know if it's possible to add an image instead of a text message?
ReplyDeleteNo doubt this could be done with a more powerful tooltip plugin, but this is an old post using native HTML. Google something not specific to APEX
ReplyDeleteHi Scott,
ReplyDeleteCould you please help me on my below tooltip requirement.
My field 'EMP_DESCRIPTION' is text format in tabular form.
I worked out above tool tip solution for a tabular form, but the problem I am facing is when I edit the column and paste the span title code in HTML Expression of the column, my field is converting into display only,but tooltip is working and showing column value in tooltip.
I need the solution such a way that when I apply tool tip my field does not change and tool tip should show the content(value) of that column.
Thanks in advance
Regards,
Antim
Try adding just the title="" tag as a custom attribute on the column instead. By using the HTML expression, you're overwriting the default tabular functionality. Otherwise, you'd need to use apex_item.text() within your SQL.
ReplyDeleteTry ask on the OTN forum for APEX if you continue to have trouble.
You may also like to read this
http://www.apex-at-work.com/2016/05/using-dynamic-tooltips-in-your.html