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] Webfocus Developer

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] Webfocus Developer
 Login/Join
 
Gold member
posted
If I have a graph that has 75 data points and the user clicks on one to popup a drill down report. is there a way to highlight the data point last clicked on in the graph so the user knows that's the data point that represents the drill down report.
Thanks

This message has been edited. Last edited by: <Kathryn Henning>,


8.0.9, Windows
excel / pdf
 
Posts: 89 | Registered: October 21, 2010Report This Post
Guru
posted Hide Post
The least expensive solution in terms of time and processing would be to put x and y information on the pop-up report.
Especially if a user can have multiple drill-down reports open at the same time.
Repainting a graph is the only solution for changing colors and though you can do this from foccache, it can take time and there's a good chance that the user will see the graph image repaint.
IHTH.
Greg



Greg



current client: WF 8.1.05 & 8.2 - Windows 7 64bit - Tomcat 7 - MRE / BID - IE11

local: WF 8.2 - Windows 7 64bit - Tomcat 6 - MRE / BID - FOCUS - IE11

PMF 8
 
Posts: 274 | Location: Boston/New England | Registered: February 12, 2006Report This Post
Gold member
posted Hide Post
Hi MMcDonald,

You can do that with JavaScript but it can be frustrating to get it working if it's your first time doing it.

gregv's solution sounds good because in an extreme case where a user clicks all 75 points he will have no way of knowing which point he clicked as number 76+.


WebFOCUS App Studio 8103
Windows7
All outputs
 
Posts: 58 | Location: London, UK | Registered: May 09, 2011Report This Post
Virtuoso
posted Hide Post
Use Javascript to rerun the graph with a parameter that sends the selected point to it so that it can be changed with conditional styling (possible in a graph? I do it in reports) and then calls the drill-down in a new window.

J.



 
Posts: 1012 | Location: At the Mast | Registered: May 17, 2007Report This Post
Gold member
posted Hide Post
I resolved my issue where I wanted to highlight the last data point a user selected in a graph. This document shows you how to identify and display the last data point selected in a graph. This is very simple to do and all the important code is below. High level overview, you have four data points the fifth data point only reflects the data point that will be a transparent red circle that has the same value as the data point you just clicked on but the marker is also enlarged to 75. Since both markers are the same value when you run the focexec from your html application they over lay each other. If the default variable you set is blank then the fifth data point is not displayed since I default to 9999999999 and I omit these values from the graph.

Focexec and Graph code:

-DEFAULT &SOLDTO='0001017518';
-DEFAULT &MATERIAL=' ';
SET ASNAMES=ON
DEFINE FILE PA_CUSTOMER_MATERIAL
XCAP/D10.2=IF STD_DEV_ITEM_TIER_MED GT 5 THEN 5 ELSE IF STD_DEV_ITEM_TIER_MED LT -5 THEN -5 ELSE STD_DEV_ITEM_TIER_MED;
RER_R/D12.2=IF REP_CONTROLLED EQ 'R' THEN XCAP ELSE 9999999999;
RER_M/D12.2=IF REP_CONTROLLED EQ 'M' THEN XCAP ELSE 9999999999;
RER_N/D12.2=IF REP_CONTROLLED EQ 'N' THEN XCAP ELSE 9999999999;
RER_O/D12.2=IF REP_CONTROLLED EQ 'O' THEN XCAP ELSE 9999999999;
XREP/D12.2=IF MATERIAL EQ '&MATERIAL' THEN XCAP ELSE 9999999999;
XANNUAL_SALES/D15=ANNUAL_SALES;
END
TABLE FILE PA_CUSTOMER_MATERIAL
PRINT
RER_R
RER_M
RER_N
RER_O
XREP
XANNUAL_SALES/D15
SOLDTO
MATERIAL
WHERE SOLDTO EQ '&SOLDTO';
WHERE ((RER_R NE 9999999999) OR (RER_M NE 9999999999) OR (RER_N NE 9999999999) OR (RER_O NE 9999999999));
ON TABLE HOLD AS 'CHART1'
END
-RUN
GRAPH FILE CHART1
PRINT
CHART1.CHART1.RER_R AS 'Rep Controlled'
CHART1.CHART1.RER_M AS 'Manufacture Controlled'
CHART1.CHART1.RER_N AS 'Non - Rep Controlled'
CHART1.CHART1.RER_O AS 'Rep Controlled - Optional Group'
CHART1.CHART1.XREP AS 'Last-Selected'
CHART1.CHART1.SOLDTO NOPRINT
CHART1.CHART1.MATERIAL NOPRINT
BY CHART1.CHART1.XANNUAL_SALES AS 'ANNUAL-SALES'
ON GRAPH PCHOLD AS HOLD FORMAT PNG
ON GRAPH SET BARNUMB OFF
ON GRAPH SET 3D OFF
ON GRAPH SET VZERO ON
ON GRAPH SET GRID ON
ON GRAPH SET GRMERGE ADVANCED
ON GRAPH SET GRMULTIGRAPH 0
ON GRAPH SET GRLEGEND 0
ON GRAPH SET GRXAXIS 1
ON GRAPH SET HAXIS 950
ON GRAPH SET VAXIS 550
ON GRAPH SET UNITS PIXELS
ON GRAPH SET LOOKGRAPH SCATTERS
ON GRAPH SET GRAPHSTYLE *
setTemplateFile("/images/tdg/template/IBIDefault.txt");
setReportParsingErrors(false);
setSelectionEnableMove(false);
setFillType(getFrame(),3);
setTextureDisplayMode(getFrame(),0);
setTextureURL(getFrame(),"/images/custom/PAB_IMAGE_1.JPG");
setPlace(true);
setScaleMax(getX1Axis(),5.0);
setScaleMaxAuto(getX1Axis(),true);
setScaleMinAuto(getX1Axis(),false);
setScaleMin(getX1Axis(),0.0);
setScaleMinAuto(getY1Axis(),false);
setScaleMin(getY1Axis(),-5.0);
setScaleMaxAuto(getY1Axis(),false);
setScaleMax(getY1Axis(),5.0);
setDisplay(getY1ZeroLine(),true);
setTextString(getTitle(),"Customer Price Standardization Analysis");
setDisplay(getTitle(),true);
setTextString(getY1Title(),"Price Variance (Std Deviations)");
setDisplay(getY1Title(),true);
setDisplay(getLegendArea(),true);
setFontStyle(getTitle(),0);
setTextString(getX1Title(),"");
setFontStyle(getY1Title(),0);
setPlaceResize(getTitle(),0);
setFontSizeAbsolute(getTitle(),true);
setFontSizeInPoints(getTitle(),12);
setPlaceResize(getY1Title(),0);
setFontSizeAbsolute(getY1Title(),true);
setFontSizeInPoints(getY1Title(),9);
setPlaceResize(getLegendText(),0);
setPlaceResize(getY1Label(),0);
setFontSizeAbsolute(getY1Label(),true);
setFontSizeInPoints(getY1Label(),10);
setPlaceResize(getX1Label(),0);
setFontSizeAbsolute(getX1Label(),true);
setFontSizeInPoints(getX1Label(),8);
setFontSizeAbsolute(getLegendText(),true);
setFontSizeInPoints(getLegendText(),8);
setTextFormatPreset(getX1Label(),6);
-*setTextString(getSubtitle(),"MATERIAL");
setDisplay(getY1Title(),true);
setFillColor(getX1Title(),new Color(0,0,255));
setFillColor(getY1Title(),new Color(0,0,255));
setTextString(getX1Title(),"Annual Sales");
setDisplay(getX1Title(),true);
setFontStyle(getX1Title(),0);
setPlaceResize(getX1Title(),0);
setDisplay(getSubtitle(),true);
setPlaceResize(getSubtitle(),0);
setFontSizeAbsolute(getSubtitle(), true);
setFontSizeInPoints(getSubtitle(), 9);
setFontSizeAbsolute(getX1Title(), true);
setFontSizeInPoints(getX1Title(), 9);
setFontSizeAbsolute(getTitle(), true);
setFontSizeInPoints(getTitle(), 14);
setFillColor(getTitle(),new Color(0,0,255));
setFontName(getTitle(),"Times New Roman");
setFontStyle(getTitle(),0);
setLogScale(getX1Axis(),true);
setLegendPosition(0);
setBorderColor(getSeries(4),new Color(255,0,0));
setTransparentFillColor(getSeries(4),true);
setMarkerShape(getSeries(4),2);
setMarkerSize(getSeries(4),75);
ENDSTYLE
ON GRAPH SET STYLE *
TYPE=DATA, COLUMN=N2,TARGET='report1',FOCEXEC=runReport(SOLDTO=N7 MATERIAL=N8 XCOUNT='1' REP_CONTROLLED='R'),$
TYPE=DATA, COLUMN=N3,TARGET='report1',FOCEXEC=runReport(SOLDTO=N7 MATERIAL=N8 XCOUNT='1' REP_CONTROLLED='M'),$
TYPE=DATA, COLUMN=N4,TARGET='report1',FOCEXEC=runReport(SOLDTO=N7 MATERIAL=N8 XCOUNT='1' REP_CONTROLLED='N'),$
TYPE=DATA, COLUMN=N5,TARGET='report1',FOCEXEC=runReport(SOLDTO=N7 MATERIAL=N8 XCOUNT='1' REP_CONTROLLED='O'),$
ENDSTYLE
END
-RUN

The javascript code I added to my html form to call a button:
This is triggered by the drilldown where focexec = runReport
function runReport(material,limit) {
document.getElementById("edit1").value = document.getElementById("edit1").value;
document.getElementById("edit5").value = document.getElementById("edit5").value;
document.getElementById("edit3").value = material;
// document.getElementById("edit4").value = limit;

var mytab6 = document.getElementById("button2");
var event1 = document.createEventObject();
mytab6.fireEvent('onclick',event1);
}

RunReport focexec code:
-HTMLFORM BEGIN


<script id=clientEventHandlersJS type=text/javascript>
var SOLDTO = "!IBI.AMP.SOLDTO;";
var MATERIAL = "!IBI.AMP.MATERIAL;";
var REP_CONTROLLED = "!IBI.AMP.REP_CONTROLLED;";
parent.runReport5(SOLDTO, MATERIAL);



-HTMLFORM END


8.0.9, Windows
excel / pdf
 
Posts: 89 | Registered: October 21, 2010Report 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] Webfocus Developer

Copyright © 1996-2020 Information Builders