Hi all, I have a requirement to show time in MM:SS format in Y axis of a graph.I have used 'HIS' format to show time in MM:SS . Suggest me how can this be done. Please find the code and the sample graph
DEFINE FILE CAR XX/HIS=HGETC(8,'HIS'); END
GRAPH FILE CAR PRINT XX ACROSS CAR ON GRAPH SET LOOKGRAPH VBAR ON GRAPH SET GRAPHEDIT SERVER ON GRAPH SET BARNUMB ON ON GRAPH SET 3D OFF 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); ENDSTYLE ON GRAPH SET STYLE * $ ENDSTYLE ENDThis message has been edited. Last edited by: Kerry,
Webfocus 7702 Unix All outputs
November 06, 2011, 04:07 PM
Waz
I don't like your chances.
The graph engine goes part the way there, but I would suggest asking Techsupport about formatting times in the graph.
Waz...
Prod:
WebFOCUS 7.6.10/8.1.04
Upgrade:
WebFOCUS 8.2.07
OS:
Linux
Outputs:
HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!
November 06, 2011, 06:41 PM
Mary Watermann
After you get the time with HIS could you not then use EDIT to remove the hour section?
WF 7.6.10, Windows, PDF, Excel
November 07, 2011, 12:32 AM
Sivashankari Venkataraman
Thanks Waz..
Hi Mary, The problem is not with the hour part , 'HIS' works fine in a tabular report. The problem when that is placed in the graph Y axis. Graph takes its own format instead of the desired mm:ss format.
Webfocus 7702 Unix All outputs
November 08, 2011, 12:30 PM
Mary Watermann
Sivashankari,
Have you looked in the documentation for graphs at the API calls?
Example: setY1LabelFormatPattern("#.#$");
-Mary
WF 7.6.10, Windows, PDF, Excel
November 10, 2011, 06:23 AM
Sivashankari Venkataraman
Hi Mary,
I did check the documentation. There is no format for mm:ss.
Thanks Shankari
Webfocus 7702 Unix All outputs
November 11, 2011, 12:57 PM
Mary Watermann
quote:
setY1LabelFormatPattern("#.#$");
I have not tried this, but did you try the following:
setY1LabelFormatPattern("##:##");
or
setY1LabelFormatPattern("0#:##");
This message has been edited. Last edited by: Mary Watermann,