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.


Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] Graph: Format Data Values with Dollar Amounts

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] Graph: Format Data Values with Dollar Amounts
 Login/Join
 
Silver Member
posted
Hello,

I am displaying a graph with the sum of amounts plotted on the Y axis.

On the Properties tab under Y-Axis, I have Value Format: $10,000. This shows the summed amount on the Y-axis correctly. However, I'm unable to format the data values.

I went to Properties --> Settings --> Graph Settings and checked the box that says "Show Data Values" - which displays the total amount above the bar, but rather than "$100,000" it shows "100,000" (same as when hovering over the data). I want it to be consistent and show "$100,000".

Please assist. My code is below:

  

ENGINE SQLORA SET DEFAULT_CONNECTION ODSP
SQL SQLORA PREPARE SQLOUT FOR
select fy,
       manager,
       sum(case when future_ask = 'Y' then amount end) future_ask,
       sum(case when pending = 'Y' then amount  end) pending,
       sum(case when past_due = 'Y' then amount end) past_due
 from prop_pipeline
where fy >= table.get_FY_function
group by fy, manager
order by fy
END
GRAPH FILE SQLOUT
SUM COMPUTE PAST_DUE_AMOUNT/D20CN=PAST_DUE; AS 'Past Due' COMPUTE FUTURE_ASK_AMOUNT/D20CN=FUTURE_ASK; AS 'Future Ask' COMPUTE PENDING_AMOUNT/D20CN=PENDING; AS 'Pending' 
ACROSS FY 
WHERE MANAGER EQ &MANAGER.(OR(FIND PROP_PIPELINE.PROP_PIPELINE.MANAGER,PROP_PIPELINE.PROP_PIPELINE.MANAGER IN prop_pipeline)).Select a Manager:.;
ON GRAPH SET LOOKGRAPH VBAR
ON GRAPH SET GRAPHEDIT SERVER
ON GRAPH SET BARNUMB ON
ON GRAPH SET 3D ON
ON GRAPH SET VZERO ON
ON GRAPH SET GRID ON
ON GRAPH PCHOLD FORMAT PNG
ON GRAPH SET GRAPHSTYLE *
setMarkerDisplay(true);
setConnectLineMarkers(false);
setConnectScatterMarkers(false);
setO1LabelDisplay(true);
setO1AxisSide(0);
setO1MajorGridDisplay(true);
setO1MajorGridStyle(0);
setO1MinorGridDisplay(false);
setAxisAssignment(0,0);
setAxisAssignment(1,0);
setAxisAssignment(2,0);
setY1LabelDisplay(true);
setY1AxisSide(0);
setY1MajorGridDisplay(true);
setY1MajorGridStyle(0);
setY1MinorGridDisplay(false);
setTextFormatPreset(getY1Label(),6);
setPieFeelerTextDisplay(1);
setPieLabelDisplay(0);
setTextFormatPreset(getPieSliceLabel(),6);
setRiserBorderMode(1);
setSeriesDefaultTransparentBorderColor(true);
setUseSeriesBorderDefaults(true);
setLegendDisplay(true);
setFontSizeAbsolute(getY1Title(),true);
setFontSizeAbsolute(getY1Label(),true);
setFontSizeAbsolute(getY2Title(),true);
setFontSizeAbsolute(getY2Label(),true);
setTextJustHoriz(getO1Title(),1);
setFontSizeAbsolute(getO1Title(),true);
setFontSize(getO1Title(),12);
setTextRotation(getO1Title(),0);
setTextWrap(getO1Title(),false);
setTextJustHoriz(getO1Label(),0);
setFontSizeAbsolute(getO1Label(),true);
setFontSize(getO1Label(),12);
setTextRotation(getO1Label(),2);
setTextWrap(getO1Label(),false);
setPlaceResize(getO1Title(),0);
setPlaceRotate(getO1Title(),0);
setPlaceAlign(getO1Title(),0);
setPlaceWordWrap(getO1Title(),0);
setPlaceResize(getO1Label(),0);
setPlaceRotate(getO1Label(),0);
setPlaceAlign(getO1Label(),0);
setPlaceWordWrap(getO1Label(),0);
setPlace(true);
ENDSTYLE
ON GRAPH SET STYLE *
$
TYPE=DATA,
     ACROSSCOLUMN=N1,
     COLOR='RED',
     FOCEXEC=app/pipeline_past_due_detail_1.fex( \
     MANAGER=&MANAGER.QUOTEDSTRING \
     ),
$
TYPE=DATA,
     ACROSSCOLUMN=N2,
     COLOR='LIME',
     FOCEXEC=app/pipeline_future_ask_detail_1.fex( \
     MANAGER=&MANAGER.QUOTEDSTRING \
     ),
$
TYPE=DATA,
     ACROSSCOLUMN=N3,
     COLOR='YELLOW',
     FOCEXEC=app/pipeline_detail_1.fex( \
     MANAGER=&MANAGER.QUOTEDSTRING \
     ),
$
ENDSTYLE
END

 

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


8009
Windows 7
Excel/HTML/AHTML/PDF
 
Posts: 34 | Location: San Francisco, CA | Registered: July 25, 2011Report This Post
<nick z>
posted
Hi,
You can add:
 
setTextFormatPreset(getDataText(),6);


in order to format Data Labels.

As for the tooltip,
You can try adding:

setUserToolTip ('[SL] for [GL] is $[YV]' );


But this may not work if you are on the older WebFOCUS release.
Thanks.
Nick.
 
Report This Post
Silver Member
posted Hide Post
Hi Nick Z,

Thank you for your assistance.

I found that:
setTextFormatPreset(getDataText(),6);


formats the data values in the bar graph with the dollar values and commas, so it displays $100,000 above the bar on the graph. Thanks!

When hovering over the data, the pop-up removes the commas that were originally there, so now displays 100000. I tried adding:

setUserToolTip ('[SL] for [GL] is $[YV]' );


but nothing changes and the hover still shows 100000 with no formatting at all (I'm on version 7.7.03).

Does anyone have any thoughts on the tooltip pop-up when hovering over each bar to display $100,000 instead of 100000?

Thanks,
Aimee


8009
Windows 7
Excel/HTML/AHTML/PDF
 
Posts: 34 | Location: San Francisco, CA | Registered: July 25, 2011Report This Post
<nick z>
posted
In WF 7703 custom tooltip setting only worked in Graph Applet mode.
You would have to change
ON GRAPH SET GRAPHEDIT SERVER
to
ON GRAPH SET GRAPHEDIT OFF

And also(very important) remove
ON GRAPH PCHOLD FORMAT PNG

But I do not recommend using Graph Applets...

Highly recommend upgrading to an 8x release.

Thanks.
Nick.
 
Report This Post
Silver Member
posted Hide Post
Hi Nick,

Thanks again for your help!

ON GRAPH SET GRAPHEDIT OFF didn't change anything and removing ON GRAPH PCHOLD FORMAT PNG gave me a java related error.

I tried to just turn off the tool tip since you helped me get the dollars display correctly on the graph, but that didn't work. I tried:
setToolTipMode(false);

We are planning to make the switch to WF8, so going to add that as part of my testing and just make the change then.

Thanks again for all of your help!


8009
Windows 7
Excel/HTML/AHTML/PDF
 
Posts: 34 | Location: San Francisco, CA | Registered: July 25, 2011Report This Post
<nick z>
posted
Hi Aimee,
to turn off tooltip:
setToolTipDisplay(false);

What errors were you getting when you tried to use applet?
What browser are you using?

Are you getting something like:
https://techsupport.informatio...et_oraclejre170.html

If you do, you need to contact CSS and they will provide you with a patch.

Thanks.
Nick.
 
Report This Post
Silver Member
posted Hide Post
Hi Nick,

Thank you, again!

setToolTipDisplay(false); did work for me and I appreciate your help with this!

I'm using Internet Explorer 10. After making the following changes:
 ON GRAPH SET GRAPHEDIT OFF
-*ON GRAPH PCHOLDFORMAT PNG

I do get the error that you mention in your link. I will contact CSS for the patch.

Thanks so much for your help with my issue. It is greatly appreciated!

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


8009
Windows 7
Excel/HTML/AHTML/PDF
 
Posts: 34 | Location: San Francisco, CA | Registered: July 25, 2011Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] Graph: Format Data Values with Dollar Amounts

Copyright © 1996-2020 Information Builders