Focal Point Banner


As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.

Join the TIBCO Community
TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.

  • From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
  • Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
  • Request access to the private WebFOCUS User Group (login required) to network with fellow members.

Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.



Read-Only Read-Only Topic
Go
Search
Notify
Tools
SVG in PDF [SOLVED]
 Login/Join
 
Member
posted
Hi all,

First post ever here, so I'm interested how it works:
I'm trying to save a webfocus generated graph and display it in a PDF report. I used the example CAR. This works. However any modifications to my own code results in gibberish:

%PDF-1.4 6 0 obj << /Length 7 0 R >> stream BT /F1 1 Tf ET 0 g /GS1 gs 0 Tc 0 Tw 0 G 0 J 0 j 1 w 10 M []0 d 1 i q 0.40 0 0 0.48 36 432 cm /Im1 Do Q BT /F1 1 Tf 12 0 0 12 18 762 Tm (PAGE )Tj 12 0 0 12 61 762 Tm ( 1)Tj 12 0 0 12 18 726 Tm (COUNTRY)Tj 12 0 0 12 111 726 Tm (SALES)Tj 12 0 0 12 161 726 Tm (RETAIL_COST)Tj 12 0 0 12 254 726 Tm (DEALER_COST)Tj 12 0 0 12 376 726 Tm (MPG)Tj ET 0.00 0.00 0.00 RG 18 720 m 68 720 l S 111 720 m 147 720 l S 161 720 m 240 720 l S 254 720 m 333 720 l S 376 720 m 397 720 l S BT 12 0 0 12 18 702 Tm (ENGLAND)Tj

Any ideas? Regards, Marco

CAR EXAMPLE
GRAPH FILE CAR
SUM SALES
ACROSS COUNTRY
ON GRAPH HOLD AS 'SALES' FORMAT SVG
END
-RUN
GRAPH FILE CAR
SUM RCOST
ACROSS COUNTRY
ON GRAPH HOLD AS 'RCOST' FORMAT SVG
END
-RUN
GRAPH FILE CAR
SUM DCOST
ACROSS COUNTRY
ON GRAPH HOLD AS 'DCOST' FORMAT SVG
END
-RUN
GRAPH FILE CAR
SUM MPG
ACROSS COUNTRY
ON GRAPH HOLD AS 'MPG' FORMAT SVG
END
-RUN
TABLE FILE CAR
SUM SALES RCOST DCOST MPG
BY COUNTRY
ON TABLE PCHOLD FORMAT PDF
ON TABLE SET STYLE *
TYPE=REPORT, IMAGE=SALES.SVG, POSITION=(0.50 2.0), SIZE=(4.0 3.0),$
TYPE=REPORT, IMAGE=RCOST.SVG, POSITION=(4.50 2.0), SIZE=(4.0 3.0),$
TYPE=REPORT, IMAGE=DCOST.SVG, POSITION=(0.50 5.0), SIZE=(4.0 3.0),$
TYPE=REPORT, IMAGE=MPG.SVG, POSITION=(4.50 5.0), SIZE=(4.0 3.0),$
ENDSTYLE
END

Solution: structure above works correctly. I build the query from scratch and now i have very sharp SVG'S!

This message has been edited. Last edited by: Marco,


7.7.04 SP04 /Windows
all output
 
Posts: 2 | Registered: October 21, 2010Report This Post
Expert
posted Hide Post
Marco, please elaborate on the modifications you're doing. I would add them one by one your working example until something breaks - have you pinpointed the problem code? Could it be something in the Java that styles the graphs?


Francis


Give me code, or give me retirement. In FOCUS since 1991

Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
 
Posts: 10577 | Location: Toronto, Ontario, Canada | Registered: April 27, 2005Report This Post
Expert
posted Hide Post
The Gibberish you posted certainly looks like the start to a PDF document.

Is this what you get back with the PCHOLD ?

If so, then this may be a mime issue.


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

 
Posts: 6347 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Report This Post
Virtuoso
posted Hide Post
quote:
This works. However any modifications to my own code results in gibberish
Do you re-run your request, or do you do a refresh of the browser window? I have seen cases where I got this junk when I did a refresh. It never happened after re-running the fex. I see same sort of results when trying to refresh a xml-page in the browser after having changed to code to produce other than xml output.


GamP

- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
 
Posts: 1961 | Location: Netherlands | Registered: September 25, 2007Report This Post
Member
posted Hide Post
Thanks for all the replies. I started to build the query from scratch again and discovered a glitch in my own code. Now I get my graphs in SVG in PDF. So problem solved. Thanks.


7.7.04 SP04 /Windows
all output
 
Posts: 2 | Registered: October 21, 2010Report This Post
Expert
posted Hide Post
Please update your first post in the thread and add [SOLVED].

Any extra info on the solution may help others in the future.


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

 
Posts: 6347 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic


Copyright © 1996-2020 Information Builders