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     SOLVED - network path in HTML output

Read-Only Read-Only Topic
Go
Search
Notify
Tools
SOLVED - network path in HTML output
 Login/Join
 
Platinum Member
posted
I have a network folder path that I want to appear in a html report output. I use the <> characters at the beginning and end of the network path to account for the space character in the folder path. However, when I run the focexec, I get an error message that the field \\abcd could not be found.

How do I include a network path with a space character as a clickable link in a -SET?

Right now I'm using -SET to assign the value to a variable:

-SET &HEAD1 = '"'|'1. Extract the text file to <\\abcd efg>.'|'"';

TABLE FILE BASELINE
PRINT
EMAIL2 NOPRINT

ON TABLE SUBHEAD 
&HEAD1.EVAL

ON TABLE SET PAGE-NUM OFF

ON TABLE SET STYLE *
TYPE=REPORT, GRID=OFF, $
ENDSTYLE

ON TABLE SET HTMLCSS ON
ON TABLE PCHOLD FORMAT HTML
END

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


Production - 7.6.4
Sandbox - 7.6.4
 
Posts: 241 | Location: Bethesda, MD | Registered: August 14, 2007Report This Post
Virtuoso
posted Hide Post
I'm not sure if this is what you want but I tried it and didn't get any errors and the space between abc efg was left intact.


-SET &HEAD1 = '1. Extract the text file to \\abcd efg.';

TABLE FILE CAR
PRINT
COUNTRY NOPRINT

ON TABLE SUBHEAD 
"&HEAD1"
ON TABLE SET PAGE-NUM OFF
ON TABLE SET HTMLCSS ON
ON TABLE PCHOLD FORMAT HTML
ON TABLE SET STYLE *
TYPE=REPORT, GRID=OFF, $
ENDSTYLE
END



WebFOCUS 8206, Unix, Windows
 
Posts: 1853 | Location: New York City | Registered: December 30, 2015Report This Post
Expert
posted Hide Post
The < causes WebFOCUS to expect a column [field) called \\abcd to be in in the table.

The quickest way to embed < and not have it translated by WF is to use the HTML entity name for the greater than and less than symbols [with pipe |):

-SET &HEAD1 = '"'|'1. Extract the text file to ' | '<' | '\\abcd efg|>.'|'"';

TABLE FILE CAR
PRINT
COUNTRY NOPRINT

WHERE RECORDLIMIT EQ 1

ON TABLE SUBHEAD 
". Extract the text file to &|lt;\\abcd efg&|gt;."

ON TABLE SET PAGE-NUM OFF

ON TABLE SET STYLE *
TYPE=REPORT, GRID=OFF, $
ENDSTYLE

ON TABLE SET HTMLCSS ON
ON TABLE PCHOLD FORMAT HTML
END


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
I would suggest using a DEFINE for the network path
And if you need to be able to click on it, then add a drill to the stylesheet.


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

 
Posts: 6347 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Report This Post
Platinum Member
posted Hide Post
quote:
Originally posted by BabakNYC:
I'm not sure if this is what you want but I tried it and didn't get any errors and the space between abc efg was left intact.


The space being intact is not the problem. The problem is that when it runs to html (and then is used in the body of the email from report caster), I want to be able to click on the link and go to that folder. With the space intact, but the link not being recognized as one text string, the link does not work.


Production - 7.6.4
Sandbox - 7.6.4
 
Posts: 241 | Location: Bethesda, MD | Registered: August 14, 2007Report This Post
Expert
posted Hide Post
As Waz suggests, use a DEFINE or COMPUTE.

As found on the web:
Use (escaped) forward slashes.
The server name and share name should be included.
Use %20 for blanks, though these are automatically added for file tags.
This will most likely only work with IE.
Reading material: Stack Overflow: What are the ways to make an html link open a folder

TABLE FILE CAR
PRINT
COUNTRY NOPRINT
COMPUTE LINK1/A100 = '<a href="file://///server-name\share-name\abcd efg">abcd efg</a>'; NOPRINT


WHERE RECORDLIMIT EQ 1

ON TABLE SUBHEAD 
"1. Extract the text file to <LINK1"

ON TABLE SET PAGE-NUM OFF

ON TABLE SET STYLE *
TYPE=REPORT, GRID=OFF, $
ENDSTYLE

ON TABLE SET HTMLCSS ON
ON TABLE PCHOLD FORMAT HTML
END


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
Virtuoso
posted Hide Post
Not to rain on your parade, but network links like that in HTML are only going to work in Internet Explorer.

Other browsers refuse to go there, mainly because of all the security risks involved. It wouldn't surprise me if even Microsoft would stop supporting that starting with their new Edge browser.

A way to provide those files for all browsers is to make those network directories available through a web-server. We did that for a couple of network directories from within IIS on our reporting server; that's an ugly hack, but it gets the job done.

IMHO, IIS should not allow to host directories that are on a remote network drive that it has no control over whatsoever, but hey, it's a Microsoft product and they do not concern themselves with security.


WebFOCUS 8.1.03, Windows 7-64/2008-64, IBM DB2/400, Oracle 11g & RDB, MS SQL-Server 2005, SAP, PostgreSQL 11, Output: HTML, PDF, Excel 2010
: Member of User Group Benelux :
 
Posts: 1669 | Location: Enschede, Netherlands | Registered: August 12, 2010Report This Post
Platinum Member
posted Hide Post
Thank you all for your help.

The %20 solution works how I want it to. When I output this to HTML, and then use that HTML output as the body of the email in the report caster task, Outlook treats the resulting link as a clickable link to the network folder.

-SET &HEAD1 = '"'|'1. Extract the text file to <\\abcd%20efg>.'|'"';

TABLE FILE BASELINE
PRINT
EMAIL2 NOPRINT

ON TABLE SUBHEAD 
&HEAD1.EVAL

ON TABLE SET PAGE-NUM OFF

ON TABLE SET STYLE *
TYPE=REPORT, GRID=OFF, $
ENDSTYLE

ON TABLE SET HTMLCSS ON
ON TABLE PCHOLD FORMAT HTML
END



Production - 7.6.4
Sandbox - 7.6.4
 
Posts: 241 | Location: Bethesda, MD | Registered: August 14, 2007Report 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     SOLVED - network path in HTML output

Copyright © 1996-2020 Information Builders