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     [CLOSED] STRREP issue in dialog manager

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED] STRREP issue in dialog manager
 Login/Join
 
Master
posted
Hai all

Can some one help me with html composer to get this?

my manager wants an adhoc form. i had all controls, list boxes etc. but he needs one control which shows all available fields that report has and user needs to select what fields he want in the report.

i tried using double list control but it outputs the strings with quotes and OR in between.

is there any way to achieve this without much coding and with GUI?

Thank you..

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


8.1.05
HTML,PDF,EXL2K, Active, All
 
Posts: 484 | Registered: February 03, 2009Report This Post
Virtuoso
posted Hide Post
The double list control is okay.

In the called focexec STRREP the ' OR ' to ' '. I think the quotes are okay, but could also use STRREP to remove.

Then PRINT &variable

Problem is the sort order...


Alan.
WF 7.705/8.007
 
Posts: 1451 | Location: Portugal | Registered: February 07, 2007Report This Post
Master
posted Hide Post
Thanks Alan. I am working on same for now.
Can you provide any sample code to remove OR using those functions?

And I dont think sort order is a problem. User can sort the fields using those arrows in double list control.
so it quotes and OR are remvoed it table request should print the fields in that sort order.


8.1.05
HTML,PDF,EXL2K, Active, All
 
Posts: 484 | Registered: February 03, 2009Report This Post
Master
posted Hide Post
be aware this is a much bigger request than he probably thinks it is...


------------------------------------
WF Environment:
------------------------------------
Server/Client, ReportCaster, Dev Studio: 7.6.11
Resource Analyzer, Resource Governor, Library, Maintain, InfoAssist
OS: Windows Server 2003
Application/Web Server: Tomcat 5.5.25
Java: JDK 1.6.0_03
Authentication: LDAP, MRREALM Driver
Output: PDF, EXL2K, HTM

------------------------------------
Databases:
------------------------------------
Oracle 10g
DB2 (AS/400)
MSSQL Server 2005
Access/FoxPro
 
Posts: 561 | Registered: February 03, 2010Report This Post
Master
posted Hide Post
Can someone help on this please?


8.1.05
HTML,PDF,EXL2K, Active, All
 
Posts: 484 | Registered: February 03, 2009Report This Post
Master
posted Hide Post
I almost got it to work but not sure what problem is happening with STRREP in dialog manager
DEFINE FILE CAR
F1/A100 = '&C2';
F2/A100 = STRREP(100,F1,2,'OR',1,' ',100,F2);
END
TABLE FILE CAR
PRINT 
CAR
F1
F2
END


this worked when
&C2 
is MODEL OR CAR OR COUNTRY.
I got F2 as MODEL CAR COUNTRY.

But when I used the same in dialog manager it gives me error.

  
-SET &C3 = STRREP(&C1LENGTH,&C2,2,'OR',1,' ',&C1LENGTH,&C3);


Can someone help plz?

Thanks

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


8.1.05
HTML,PDF,EXL2K, Active, All
 
Posts: 484 | Registered: February 03, 2009Report This Post
Master
posted Hide Post
This worked but when I replace last parameter A100 with A&C1LENGTH, it gives me error. any clue?


8.1.05
HTML,PDF,EXL2K, Active, All
 
Posts: 484 | Registered: February 03, 2009Report This Post
Expert
posted Hide Post
STRREP does not like a blank replacement character.

You could try the following:

-SET &C2 = 'MODEL OR CAR OR COUNTRY';

-SET &C3 = STRREP(&C2.LENGTH, &C2, 2, 'OR', 0, 'X', 100, 'A100');

-TYPE &C3

Between each value is ' OR '. Since you're only replacing the 'OR' there will be two blanks between each value, so the replacement string can have a length of zero, with the X as a dummy character that is not used.

Beware of using STRREP to replace 'OR' - this will mess up a value such as 'OREGON'.


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
Expert
posted Hide Post
quote:
This worked but when I replace last parameter A100 with A&C1LENGTH, it gives me error. any clue?

Use 'A|&C1LENGTH'

And, heed Francis's warning...


Tom Flynn
WebFOCUS 8.1.05 - PROD/QA
DB2 - AS400 - Mainframe
 
Posts: 1972 | Location: Centennial, CO | Registered: January 31, 2006Report This Post
Master
posted Hide Post
This is still giving error tom. it says &c1length not found
quote:
Originally posted by Tom Flynn:
quote:
This worked but when I replace last parameter A100 with A&C1LENGTH, it gives me error. any clue?

Use 'A|&C1LENGTH'

And, heed Francis's warning...


8.1.05
HTML,PDF,EXL2K, Active, All
 
Posts: 484 | Registered: February 03, 2009Report This Post
Expert
posted Hide Post
You can't put partial code here, we are not mind reader's.

I will "now assume' that the the values coming in are in &C1. If so, the syntax is incorrect, it s/b:

'A|&C1.LENGTH'


Tom Flynn
WebFOCUS 8.1.05 - PROD/QA
DB2 - AS400 - Mainframe
 
Posts: 1972 | Location: Centennial, CO | Registered: January 31, 2006Report This Post
Virtuoso
posted Hide Post
quote:
Beware of using STRREP to replace 'OR' - this will mess up a value such as 'OREGON'

This can be overcome by replacing the OR with the trailing and leading space, as follows:
-SET &C2 = 'MODEL OR CAR OR COUNTRY';
-SET &C3 = STRREP(&C2.LENGTH, &C2, 4, ' OR ', 1, HEXBYT(32,'A1'), &C2.LENGTH, 'A&C2.LENGTH');
-TYPE &C3


GamP

- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
 
Posts: 1961 | Location: Netherlands | Registered: September 25, 2007Report This Post
Expert
posted Hide Post
Nice trick with the HEXBYT.


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     [CLOSED] STRREP issue in dialog manager

Copyright © 1996-2020 Information Builders