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.
I do not think that there is something like that available in webfocus. You'll have to do this 'yourself', meaning you'll need to create defines and/or computes to provide the tags at the desired places and output the result as an alpha hold file. The HOLD FORMAT XML that webfocus provides sort of holds it according to the needs of webfocus itself, which is not neccessarily xml-standard.
GamP
- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
Posts: 1961 | Location: Netherlands | Registered: September 25, 2007
Word definately will not read a WebFOCUS XML or XMLR (extended XML that contains a complete report not just the data).
Any reason why you specifically want to use XML?
Would format DOC not give you what you want? It will open directly in word.
Unfortunately no styling is possible but that would be true with XML as well unless you incorporate all the styling that word requires which would be extremely difficult to do.
Originally posted by shakila25: To generate an xml in webfocus and save it as word document.
I was hoping for a little more info. Are you looking to hold the file to the server disk, as in "ON TABLE HOLD", or, are you looking for the users to request the report - like 95% of WebFOCUS requests - and have it open in MS WORD? Or is it something else entirely?
"There is no limit to what you can achieve ... if you don’t care who gets the credit." Roger Abbott
I created a quick-and-dirty solution to address a similar need. I 'generate' the XML in HTML, open it in a browser, then copy and paste the output into a text document. It's not sexy but it works for us. I'm sure you could play with this and get it to format correctly for your output needs.
-SET &NBSP = '&'||'nbsp;';
-SET &TAB5 = &NBSP||&NBSP||&NBSP||&NBSP|| 
-SET &TAB4 = &NBSP||&NBSP||&NBSP|| 
DEFINE FILE CAR
LTN/A1 = HEXBYT(60,'A1');
XMLHDR/A40 = '?xml version="1.0" encoding="UTF-8"?>';
CMDS_O/A20 = 'CARFILE>';
CMDS_C/A11 = '/CARFILE>';
END
TABLE FILE CAR
PRINT
COMPUTE DETAILTAG/A80 = 'cdetail>'; NOPRINT
COMPUTE COUNTRYTAG/A80 = 'country>'||COUNTRY||'&|lt/country>'; NOPRINT
COMPUTE CARTAG/A80 = 'car>'||CAR||'&|lt/car>'; NOPRINT
BY COUNTRY NOPRINT
ON TABLE SUBHEAD
"&|lt<XMLHDR"
"&TAB5&|lt<CMDS_O"
ON COUNTRY SUBHEAD
"&TAB5&TAB5&|lt<DETAILTAG"
"&TAB5&TAB5&TAB5&|lt<COUNTRYTAG"
"&TAB5&TAB5&TAB5&|lt<CARTAG"
"&TAB5&TAB5&|lt/cdetail>"
ON TABLE SUBFOOT
"&TAB5&|lt<CMDS_C"
ON TABLE SET PAGE-NUM NOPAGE
ON TABLE SET HOLDLIST PRINTONLY
ON TABLE NOTOTAL
ON TABLE PCHOLD FORMAT HTML
END
IF I VIEW THE SOURCE AND SAVE AS XML. IF I RUN THE XML FILE AM GETTING THE BELOW ERORR.
----ERROR:-----
The XML page cannot be displayed Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh button, or try again later.