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.
Example: When the graph has 20 bars, the size (width) of each bar is different from when the graph has 3 bars. The bar size (width) changing according to the number of bars in the graph.
Is there any way to have the bar's size same irrespective of the number of bars in the graph?
ThanksThis message has been edited. Last edited by: FP Mod Chuck,
It looks as though setRiserWidth() relates the percentage of the available space for the riser. So, if you really want to achieve this, you would have to resort to some calculation outside of your graph and maybe set the HAXIS and VAXIS according to the number of expected risers.
T
In FOCUS since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2
WebFOCUS App Studio 8.2.06 standalone on Windows 10
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004
But doing that, the graph frame size won't be same across graphs. A report can have many graphs and the maximum number of bars in each graph can be up to 20. So dynamically i need to find the number of bars and for the remaining (20 - number of bars), i need to create dummy bars.
Use the COLUMNS syntax with blank values to do that. Something like -
-DEFAULT &Max_Cols = 20
-SET &ECHO=ALL;
TABLE FILE CAR
PRINT CAR
WHERE COUNTRY EQ 'ITALY' OR 'FRANCE' OR 'ENGLAND'
ON TABLE SAVE
END
-RUN
-SET &Count = &Max_Cols - &LINES;
-SET &Columns = 'COLUMNS ';
-READ SAVE, &Car
-REPEAT :Loop1 WHILE &IORETURN EQ 0;
-SET &Columns = IF &Columns NE 'COLUMNS ' THEN &Columns | ' AND ' ELSE &Columns ;
-SET &Columns = &Columns | '''&Car.EVAL''' ;
-READ SAVE, &Car
-:Loop1
-REPEAT :Loop2 &Count TIMES;
-SET &Columns = &Columns | ' AND ' | ''' ''' ;
-:Loop2
GRAPH FILE CAR
SUM RCOST
ACROSS CAR &Columns
ON GRAPH SET GRAPHSTYLE *
ENDSTYLE
END
This will always give the same number of risers as the value in &Max_Cols.
T
In FOCUS since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2
WebFOCUS App Studio 8.2.06 standalone on Windows 10
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004
Hi Tony, Your code is working fine. But when I apply the same code in my code, I am getting the following error message. Please have a look.
-*********** GRAPH FILE TEST SUM TOT_AMT AS 'Amount' ACROSS NAME AS '' COLUMNS 'Antony' AND 'Sachin' AND 'Shankar' AND 'Nitesh' AND ' ' AND ' ' AND ' ' AND ' ' AND ' ' AND ' ' AND ' ' AND ' ' AND ' ' AND ' ' AND ' ' AND ' ' AND ' ' AND ' ' AND ' ' AND ' ' ON GRAPH SET GRAPHSTYLE * ENDSTYLE END
0 NUMBER OF RECORDS IN GRAPH= 4 PLOT POINTS= 0 NO DATA TO GRAPH -***********
Don't know which version you are using but look at page 149 (also available in other document version at different page): Adding Color-By and Size-By Fields. Maybe the solution is there. Creating HTML5 Charts
WF versions : Prod 8.2.04M gen 33, Dev 8.2.04M gen 33, OS : Windows, DB : MSSQL, Outputs : HTML, Excel, PDF In Focus since 2007
Posts: 2409 | Location: Montreal Area, Qc, CA | Registered: September 25, 2013
Thanks for the recommendations, but the "bucket" command just broke everything, and apparently doesn't work with VBAR. The jschart settings when copied whole-cloth stop the graph from printing without providing an error message.
This seems like a painfully simple, painfully obvious option that should just have a really really basic setting like "WIDTH=10" but apparently that's not the case.
My GRAPH TABLE command produces a separate graph for each month. Completed months are similar enough that it doesn't matter, the newest month, especially on the 1st day, look absurd. I'd just like them to show one bar the same width as the other graphs and then blank space to the right of that.This message has been edited. Last edited by: John_Edwards,
Posts: 1012 | Location: At the Mast | Registered: May 17, 2007
So your charts are for all days of a month? Why not just force the day numbers that you need? Any months that do not have 31 days, you could just add a dummy enforced column as per my reply to Antony.
T
In FOCUS since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2
WebFOCUS App Studio 8.2.06 standalone on Windows 10
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004