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     Formatting Selection Criteria in Report Header

Read-Only Read-Only Topic
Go
Search
Notify
Tools
Formatting Selection Criteria in Report Header
 Login/Join
 
Gold member
posted
I want to format the selection criteria in the report header. This selection criteria is being passed from a different application and I am using -set commands to display that conditionally in the report header.

-SET &ACCOUNTCLASSDESC = IF &IACCOUNTCLASSDESC EQ '' THEN 'Account Class: All' ELSE 'Account Class: ' ||&IACCOUNTCLASSDESC ;
-SET &METHODDESC = IF &IMETHODDESC EQ '' THEN 'Call Method: All' ELSE 'Call Method: ' ||&IMETHODDESC ;
-SET &SEGDESC = IF &IMARKETSEGMENTDESC EQ '' THEN 'Segment: All' ELSE 'Segment: ' || &IMARKETSEGMENTDESC;
-SET &REPORTCATEGORY = IF &IMEREPORTCATDESC EQ '' THEN 'Report Category: All' ELSE 'Report Category: ' ||&IMEREPORTCATDESC;

-* Report Header
ON TABLE SUBHEAD
"&ACCOUNTCLASSDESC<+0>&SEGDESC<+0>&METHODDESC<+0>&REPORTCATEGORY<+0> <+0> "

-- The final result if none selected

Account Class: All Segment: All Call Method: All Report Category: All

-- The final result if something is selected

Account Class: TEST Segment: TEST2 Call Method: TEST3 Report Category: TEST4

I would like to have the value in different color to differentiate it from the title.

so, the titles Account Class, Segment, Call Method, Report Category will be in black and the selected values will be in 'RED'.

Can we do this using -Set commands ? Does anyone have any sample code ?

Thank you,
KK


Test - Webfocus 7.6.7
Prod - Webfocus 7.6.7
Win2003
Sql Server 2000 and 2008
 
Posts: 59 | Registered: May 01, 2007Report This Post
Virtuoso
posted Hide Post
Yes it can

you are using the grid, and each item of that grid can get a different fontcolor, bold setting etc, only the background is always the same per line (I just found out today)
So what you need to change is that the text "account class" is not in your amper field, but hard coded in the header and in a separate grid field.

In the code you have to say something like

TYPE=HEADING,LINE=3,OBJECT=TEXT,ITEM=1,SIZE=10,
COLOR=RGB(70 96 149),BACKCOLOR='WHITE',STYLE=BOLD,JUSTIFY=LEFT,WIDTH=4.625,$
TYPE=HEADING,LINE=3,OBJECT=TEXT,ITEM=2,SIZE=10,COLOR=RGB(70 96 149),
BACKCOLOR='WHITE',STYLE=BOLD,JUSTIFY=LEFT,WIDTH=1.125,$
TYPE=HEADING,LINE=3,OBJECT=TEXT,ITEM=3,SIZE=10,
COLOR=RGB(70 96 149),BACKCOLOR='WHITE',STYLE=BOLD,JUSTIFY=LEFT,WIDTH=1.125,$




Frank

prod: WF 7.6.10 platform Windows,
databases: msSQL2000, msSQL2005, RMS, Oracle, Sybase,IE7
test: WF 7.6.10 on the same platform and databases,IE7

 
Posts: 2387 | Location: Amsterdam, the Netherlands | Registered: December 03, 2006Report This Post
Silver Member
posted Hide Post
quote:
ON TABLE SUBHEAD
"&ACCOUNTCLASSDESC<+0>&SEGDESC<+0>&METHODDESC<+0>&REPORTCATEGORY<+0> <+0> "


- Yes we can do this. You can use
TYPE=SUBHEAD, BY=1, ITEM=1, COLOR=BLACK, $
TYPE=SUBHEAD, BY=1, ITEM=2, COLOR=READ, $ to apply color to an individual item in subhead..

Now in your example

&ACCOUNTCLASSDESC - is combination of label and value , and you want label colored black and value ('All') colored red
so here is what I think you may do

SET &ACCOUNTCLASSDESC = IF &IACCOUNTCLASSDESC EQ '' THEN 'All' ELSE &IACCOUNTCLASSDESC ;
-SET &METHODDESC = IF &IMETHODDESC EQ '' THEN 'All' ELSE &IMETHODDESC ;
-SET &SEGDESC = IF &IMARKETSEGMENTDESC EQ '' THEN 'All' ELSE &IMARKETSEGMENTDESC;
-SET &REPORTCATEGORY = IF &IMEREPORTCATDESC EQ '' THEN 'All' ELSE &IMEREPORTCATDESC;

-* Report Header
ON TABLE SUBHEAD
"Account Class:<+0>&ACCOUNTCLASSDESC<+0>
All Segment:<+0>&SEGDESC<+0>
Call Method:<+0>&METHODDESC<+0>
Report Category:<+0>&REPORTCATEGORY<+0> <+0> "

and then apply stylesheet above to color each item the way you want them colored.
item 1,3,5 & 7 are all labels and
item 2,4,6 & 8 are selected values..

Hope this helps !!


-Yogesh Patel
------------------------------------------------------------------------
PROD: WF 764 on Linux Apache tomcat v5.5
DEV: WF 768 on Linux
 
Posts: 42 | Location: Edison, New Jersey | Registered: January 30, 2007Report This Post
Gold member
posted Hide Post
Thank you Frank and Yogesh.

I will try that and get back to you.

KK


Test - Webfocus 7.6.7
Prod - Webfocus 7.6.7
Win2003
Sql Server 2000 and 2008
 
Posts: 59 | Registered: May 01, 2007Report This Post
Expert
posted Hide Post
The only addition I would make to that is to use RED instead of READ Wink.

Also check out the article by Susannah Jones entitled "What is Indian Red anyway" which gives a good overview of what colours that Excel can display (yes they are limited!!).

Another excellent site (again thanks to Susannah for putting me onto this one) is www.colorsontheweb.com

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, 2004Report This Post
Expert
posted Hide Post
WHERE IS SUSANNAH???

I miss her wit, style, and knowledge. I hope she is OK!!!


Tom Flynn
WebFOCUS 8.1.05 - PROD/QA
DB2 - AS400 - Mainframe
 
Posts: 1972 | Location: Centennial, CO | Registered: January 31, 2006Report This Post
Platinum Member
posted Hide Post
Why not simplify your task and convert one-row-of-three into 3-rows-of-one.
'Echo' the filter specs in a two column by 3 row diaplay. Put the filter's name in the first column and it's value in the 2nd column. Use <+n> spacing controls to left-justify both columns.
Takes up more vertical realestate but it's simpler to code and just as easy to read as colors.


WIN/2K running WF 7.6.4
Development via DevStudio 7.6.4, MRE, TextEditor.
Data is Oracle, MS-SQL.
 
Posts: 154 | Location: NY | Registered: October 27, 2005Report This Post
Expert
posted Hide Post
I think Susannah's OK and she still has her sense of humour!

https://forums.informationbuilders.com/eve/forums/a/tpc/...551089932#5551089932


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
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     Formatting Selection Criteria in Report Header

Copyright © 1996-2020 Information Builders