Conditionally format PDF output

Hi
In my report, I use this technique to highlight in red some rows:
      case when a.completed_date is null then
          '<div style="color:red">'||a.action_description||'</div>'
      else a.action_description end action_description,However, the div part is ignored when the report is exported to PDF (using Apache FOP) and all rows display in black.
To fix it, I created a new report template and added a conditional display to it:
<xsl:if test="contains(.//#COLUMN_HEADER_NAME#, 'color:red')">
<fo:inline xsl:use-attribute-sets="highlight">
<xsl:value-of select="#COLUMN_HEADER_NAME#"/>
</fo:inline>
</xsl:if>
I.e., if the column contents contains "color:red" it should print using the highlight attribute set. However it does not work. If I remove the div (so the color:red part actually displays in the report) it works.
So I guess that all html tagging is removed before passing the data to the PDF generation -- is this correct? Any advice on how to implement this in that case?
Thanks,
Luis

Marc,
Thanks for the response. There is another column in the report ("Status") on which I can base my logic to conditionally display one or another block, but this layout, obviously, will be specific to that report.
I was just wondering if it could be done it in a more generic way... apparently not!
Cheers,
Luis

Similar Messages

  • Access conditional formatting pdf has no color

    I've built conditional formatting (using colors) in an Access (2003) database report. When I convert the report to pdf using the pdf maker icons (version 7), the conditional formatted boxes that are usually colored, are dark.
    What to do to make the colros show.

    Did you receive any answer? I got the same problem.
    BR
    Névoa

  • Query about Email Address Format & PDF Output

    I'm using XML Publisher and an RTF word template linked to an Oracle XML file to generate PDF Purchase Orders.
    Part of the PDF output displays an email address.
    If the email address is in this format:
    [email protected]
    then when the PDF output is generated, the address is outputted into a clickable hyperlink which sends an email to:
    [email protected]
    However, if the email address is set to:
    [email protected]
    then the resulting email hyperlink will only be sent to:
    [email protected] (i.e. all to the right of the dot)...
    Just wondered if there is any way to stop this from happening?
    Thank you

    Sorry - I know months have passed since I first raised this query.
    Just double checking again, to see if anyone is aware of a workaround for this email issue? Is there anything I can do in the XSL in the background to force a particular email hyperlink format?
    Thank you

  • Creating a nicely formatted PDF output, suggestions/stratigies?

    I really wanted to call this "Stupid Questions 101", but figured this was probably a better thread title.
    I think this is going to rather long, as I have many variables and other considerations, so let me start off trying to explain.
    I finally have my application pretty much finished (at least the initial version, have to see what users say). Now, I also need to add the capability for a nicely formatted report that's rather complicated, preferably as a PDF file. The final result needs to look like pages from a book (different fonts, lots of whitespace, left, right and center alignement, etc.) instead of a standard report layout.
    So first, I have about 30 tables (views actually). For this application, I need to produce a report that goes through all of the views and 'dumps' all of the information in each table for whatever 'parent' record the user wants. There's going to be lots of looping, and I have the typical parent - child - grandchild relationships, so when I'm printing the child record, before progressing to the next child record, I also need to print all of the assosciated grandchild records.
    A couple views can be simply output in one line, like the simple report format. Most views though need to formatted across multiple lines, like a form. Many fields will also need to be wrapped across multiple lines, adding to the whitespace and indenting problem.
    All together, I have around 300 fields or so that I need output, so as I understand it, ApEx itself can't handle this as a web page (besides all the various looping problems, but also the 100 'item' limit), so I'm thinking that I'll need to create a page with a PL/SQL region and write a package (with all of the views getting their own procedure), that will go through all of the looping etc. I'll need for the 'dump'.
    So, I'm wondering which is the best approach to take on this, I don't think I can use a PSP page to accomplish this, so I think I just need to use the web toolkit.
    1. Should I start my PL/SQL region off with the "pre" tag, so my 'layout' stays intact?
    2. I'll also need to print my field 'labels' in bold, so will the "pre" tag interfere with that?
    3. Will it be easier to place the htp.p statements in my package's procedures, or just write the package with the htp.p statements and add those with the PL/SQL region on the page? (But then I'll need to use dbms.output to send the data to the region won't I?)
    4. Since this will wind up (hopefully) as a nicely formatted region on the page (with lots of whitespace, etc.), will the FOP package allow me to create it (just the region, not the entire page) as a PDF, or does the FOP package only work with standard ApEx 'reports'?
    5. Am I way off base here, or is there a better aproach I'm missing? I really need to try and keep everything free (otherwise I'd consider PL/PDF), as being in the government, money is usually pretty tight, we usually only have money just for our salaries and office space.
    Like I said above, pretty stupid questions, but I haven't used the web toolkit in about 7 years or so, being tied up with merging two database and cleaning up the data from one of them (it had no data validation or integrity constraints at all, everything was a free-form field, like a giant spreadsheet).
    Thanks for any suggestions on how to best tackle this next stage of my problem.
    Of to start experimenting some.
    Bill Ferguson

    For anybody following this, here's a couple updates.
    I decided to go with an internal stylesheet, vs. an external (one less file I need to worry about moving during an upgrade, machine change, etc.). Since I'm generating the entire page through a PL/SQL package anyway, the internal stylesheet stays with the code, just in a separate procedure.
    I'm having problems getting a button to fire off the javascript to popup a new window that runs the package. I can run the package fine if I start a new window manually and supply the URL/user.package.procedure, so it's something with where I'm placing the javascript call. I've searched the forums, and the closest I found to an answer was to add the code to the "Image Attributes", but when I tried that, it insisted on an image also being specified. Since I don't have an image, or know of any, I tried both the "HTML Button" and "Template Based Button", but those grey out the "Image Attributes", and the javascript doesn't seem to fire from the "Button Attributes".
    The (edited) javascript call is:
    onclick="javascript:MypopUp2
    ('http://my_machine:my_port/mrds/usgs.print_site.print_doc?dep_id_in=&P0_DEP_ID.',800,600);"Anybody have any ideas on what/where I really need to place this? The javascript does work elsewhere, it's simply a copy of the popup2 script in core.js that I moved over into my own javascript file.
    On a different note, since I'm learning about css as I progress, I discovered that using "div" "/div" causes a new line, while "span" "/span" does not (angle brackets replaced with quotes). Took me a while to get figured out, it was really messing up my formatting, so maybe somebody else just learning this css stuff can save a few headaches.
    Hope somebody knows where to add the code to the button. :^)
    Bill Ferguson

  • Terms and Conditions in pdf output but not printing

    Hello all,
    I had this similar issue with my cover letter, but I could move the call to xml control file and that resolved the issue. But with T&C, I need to print them on back of every page and I've used the logic from Tim's blog (http://blogs.oracle.com/xmlpublisher/2007/10/here_are_my_terms_conditions.html, thanks Tim!). It works great if I have a simple call to the T&C subtemplate. I have to check for the conditions though, and that's when my printed/emailed output contains blank for T&C. Output of the report has alternate pages of T&C. Here's my call to the subtemplate:
    <?if:(//DCRD_OKSQUOTE_GROUPED/CS_PRINT_ARTICLES=’Y’) and (//DCRD_OKSQUOTE_GROUPED/LIST_G_CONTRACT/G_CONTRACT/CF_ARTICLE_TYPE=’ONCALL’)?><?call:OnCallArticle?><?end if?><?section:force-page-count;'end-on-even-layout'?><?section:xdofo:blank-on;'even-skip-page-count'?>
    The version that works is:
    <?call:OnCallArticle?><?section:force-page-count;'end-on-even-layout'?><?section:xdofo:blank-on;'even-skip-page-count'?>
    Appreciate all the help.
    TIA,
    Alka

    Just before the end of your for-each loop make a call to a sub-template
    Your sub-template will have the terms and conditions.
    regards
    Jorge

  • Format Pdf Output

    Hi Friends,
    I am trying to suppress the records in my RTF template.
    My current output is something like this.
    supplier Site Invoice Desc Amount
    ABC      XYZ     1     ABCDF     100
    ABC     XYZ     2     EFGH     200
    ABC     XYZ     3     HFHG     300
              Supplier Total:
    DEF     YYY     1     ABCDF     100
    DEF     YYY     2     EFGH     200
    DEF     YYY     3     HFHG     300
              Supplier Total:
    #############Expected Output###########
    supplier Site Invoice Desc Amount
    ABC     XYZ     1     ABCDF     100
              2     EFGH     200
              3     HFHG     300
              Supplier Total:
    DEF     YYY     1     ABCDF     100
              2     EFGH     200
              3     HFHG     300
              Supplier Total:
    Any suggestions please.?
    Many Thanks..!

    Can you post a sample of your XML data and explain why you trying to do what you are trying to do?

  • PDF output with conditional text

    I need to create two PDFs from my project, each displaying a different conditional build expression, but I can't figure out how to do it. Selecting PDF Output doesn't show options like, for example, WebHelp does, unless I've missed something in the setup. Is this possible? My reviewers want to review hardcopies although I've tried to convince them that they should look at it as it will be displayed online.

    Hi there
    See if the video linked below helps.
    Click here
    Cheers... Rick

  • PDF output not retaining same formatting as done in RTF

    Hi All,
    I have created a RTF template and need to show the output in PDF. Now in the RTF, as per the requirements, I am not enclosing my form fields in any table or inside any tabular cells. So I have to display the output something like this
    Name : Peter
    Age : 30 years
    Address : New Jersy
    Dept : Accounts
    but after placing the form fields in their right places, when I see the output in PDF, the formatting is lost and values are NOT displayed at their desired places as set in the RTF template. So I get the PDF output something like this
    Name : Peter
    Age:
    30 years
    Address :
    New Jersy
    Dept :
    Accounts
    Is there a method to fix the form fields so that they don't move and i get the output in the same way as I have designed in the RTF template.
    Any help on this would be much appreciated.
    Thanks,
    Ronny

    Ronny,
    There is the concept of CONTEXT COMMANDS:
    http://docs.oracle.com/cd/E12844_01/doc/bip.1013/e12187/T421739T481157.htm#con_freeform
    It may help to get what you want along with the example from the XML Publisher blog:
    http://blogs.oracle.com/xmlpublisher/entry/inline_grouping
    regards
    Jorge

  • PDF Output File Format

    Hi all,
    Does somebody know what is the PDF output file format in Oracle EBS 11.5.10.2?
    Is it PDF/X, PDF/E, PDF/UA, PDF/VT or something else?
    Thanks and regards,
    Karmit

    Hi,
    See this thread.
    concurrent ouput to email
    concurrent ouput to email
    Regards,
    Hussein

  • Broadcast Email to PDF output format

    Hi All,
    We are using the standard web template (0ANALYSIS_PATTERN) to broadcast email for PDF output format. I'm managed to received the PDF attachment email but however instead of one query, it contains duplication of the same query (repeated query) in the PDF file. We are also using the standard 0QUERY_TEMPLATE_BROADCAST_PDF web template.
    Has anyone experience this issue before and what is the solution for this?

    Hi All,
    We are using the standard web template (0ANALYSIS_PATTERN) to broadcast email for PDF output format. I'm managed to received the PDF attachment email but however instead of one query, it contains duplication of the same query (repeated query) in the PDF file. We are also using the standard 0QUERY_TEMPLATE_BROADCAST_PDF web template.
    Has anyone experience this issue before and what is the solution for this?

  • Can we Compare PDF Output with CSV format

    Team,
    Can we Compare PDF Output with CSV format.
    In Excel I need to two text boxes asking us to browse the files and compare the files PDF & CSV format.
    Please suggest me if we have solution for this.
    Thanks!
    Kiran

    Hi
    I'm afraid the Excel Application does not support this function currently, I am suggesting you to take advantage of a third party component to achieve this goal.
    Thanks for your understanding.
    Best Regards
    Lan
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Conditional pdf Output for a report

    Hi, depending on the value for one particular filed in my XML, I need to generate the pdf output.
    For eg.. If Reqd = 'N', I don't want the XML publisher to generate the pdf output else if the value is 'Y', it should generate the output.
    In my current implmenetation, The pdf report is getting generated for all cases.. i need to put the above mentioned check to restrict it .
    If you have an idea on how to acheive it, please let me know.
    Thanks and Regards
    Madhu

    Hi,
    The first thing you'll need to do is to create a form field before any content in your rtf file.
    The form field shall contains the following code in the Add help text:
    <?if:REQD='N'?>Restricted content..<?end if?>
    <?if:REQD='Y'?>The next form field shall be placed in the bottom of your file, containing:
    <?end if?>I hope that helps.
    BR
    Kenneth
    Edited by: Kenneth_ on 2010-09-22 09:05

  • XML Publisher Report not generating the PDF output.

    Hi,
    I am trying to develop a XML Publisher Report in R12 Vision Instance.
    I have developed the rdf report and concurrent program with XML as output format. Ran the concurrent program and I got the XML output. Based on XML output I have created the rtf template. Using both the template and xml output I have created in Data Definition and Template in XML Publisher Administrator Responsibility. Now I am comming to the concurrent program and running the program, here instead of generating the PDF output it is generating again the XML output and concurrent program completing with warning status.
    When I am trying to do the same in 11i Vision Instance, Concurrent Program completing with normal status and when trying to view the output it is saying "Unable to Publish output for the Processed Request".
    Kindly please help me out in this issue.
    Thanks,
    Manasa.

    Hi Mahesh,
    Here the concurrent programs are not erroring out. It is completing with Warning status and when we click on View Output the output is coming in XML format instead of PDF, this is in R12 Vision Instance.
    In 11i Vision Instance, concurrent program is completing with Normal Status but when we click on View Output it is saying "Unable to Publish output for specified request".
    Thanks,
    Manasa.

  • PDF output does not refresh data in BI Publisher, XML and HTML do refresh

    I just upgraded to BI Publisher 10.1.3.4.0 and I noticed that the PDF format of the reports does not reflect recent changes in data, while XML data and HTML output do reflect changes in data immediately.
    I'm using BI Publisher to print APEX applications reports. When I change some data in APEX forms, I click again in the Print button and the data remains unchanged. I made some testing inside Oracle BI Publisher, and noticed that XML data and HTML output do reflect changes, but PDF output remains with the old data for some unknown amount of time. I cannot identify a method to force the PDF to refresh, just un-log and log in again several times until the data appears updated. This is serious because when users change data and print again, they expect the changes to be reflected in the new printable report, and may not notice that the data is the old version.
    OS is Oracle Enterprise Linux.
    Any help on this will be very welcome.
    Francisco

    Open the report in Edit Mode Click on the reports and in the properties section Uncheck the
    Enable Document Cache Property and your issue should be resolved.

  • Animated GIF in PDF output

    Hi all,
    is it possible to hand an animated GIF to the PDF output (remaining animated)?
    FM10 and AcrobatX work together rather fine concerning other animation formats such as SWF or AVI. I am not sure however wether the PDF format supports animated GIFs at all.
    Robert

    As a side, I've never ever got an embedded avi to covert to pdf.  I do it all in the pdf.

Maybe you are looking for