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] Display message from focus file on Dashboard Banner

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] Display message from focus file on Dashboard Banner
 Login/Join
 
Platinum Member
posted
Hi,
Is there a way to put a custom message on the Dashboard Banner that reads the message from a webfocus table.
Right now I have the following code in banner.html template. However I would like the message (Todays Message!)to be able to be read from a focus file.


	< !--$Revision: 1.6 $:-->
< !--  logoCellWidth = 200 logoCellHeight = 80 -->

<html>
<head>
<title>WebFOCUS Operational Management Portal</title>
<script language="javascript" src="worp_banner.js" type="text/javascript"></script>
</HEAD>
<BODY style="OVERFLOW: auto" leftMargin=0 topMargin=0 onunload=java_script:closeAllWindows[) MARGINHEIGHT="0" MARGINWIDTH="0">
<TABLE  WIDTH="100%" BORDER="0" CELLSPACING="0" CELLPADDING="0">
<TR height="25" class="bg2">
<TD></TD>
<TD ALIGN="right" VALIGN="middle">
<SPAN CLASS="text">
< !--Links-->
</SPAN>
<IMG SRC="clear_space.gif" WIDTH="25" HEIGHT="10" BORDER="0">
</TD></TR>
<TR height=80>
<TD class=bg3 vAlign=top align="left" width=600>
<TABLE WIDTH="40%" class="bg3" align="left" valign="top"><IMG SRC = "logo.gif" ID="Company Logo" BORDER="0"></TD>
<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
<TBODY>
<TR class=bg1 WIDTH="*">
<FONT face=arial color=red size=4 valign="top" align="left">
[b]
<MARQUEE scrollAmount=10 scrollDelay=150 loop=true width=100% height=20>
<BLINK>Todays Message!</BLINK></MARQUEE>[/b]</FONT></TR>
<TR class=bg1 height=25>
<TD class=bg1 width="100%">ERP Dashboard </TD></TR></TBODY></TABLE>
</BODY></HTML>

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


App Studio Version 8202
windows Platform
SQL Server 2008/2012
 
Posts: 183 | Location: TX | Registered: January 22, 2007Report This Post
Master
posted Hide Post
Create a fex file and use HTMLFORM.
TABLE FILE CAR
SUM
COMPUTE URMSG/A50='Custom Text: Place your message here!';
SALES
SALES NOPRINT
ON TABLE HOLD AS HLD FORMAT ALPHA
END
-RUN
-READ HLD &URMSG.A50.
-TYPE &URMSG

-HTMLFORM BEGIN
< !--$Revision: 1.6 $:-->
< !-- logoCellWidth = 200 logoCellHeight = 80 -->

<html>
<head>
<title>WebFOCUS Operational Management Portal</title>
<script language="javascript" src="worp_banner.js" type="text/javascript"></script>
</HEAD>
<BODY style="OVERFLOW: auto" leftMargin=0 topMargin=0 onunload=java_script:closeAllWindows[) MARGINHEIGHT="0" MARGINWIDTH="0">
<TABLE WIDTH="100%" BORDER="0" CELLSPACING="0" CELLPADDING="0">
<TR height="25" class="bg2">
<TD></TD>
<TD ALIGN="right" VALIGN="middle">
<SPAN CLASS="text">
< !--Links-->
</SPAN>
<IMG SRC="clear_space.gif" WIDTH="25" HEIGHT="10" BORDER="0">
</TD></TR>
<TR height=80>
<TD class=bg3 vAlign=top align="left" width=600>
<TABLE WIDTH="40%" class="bg3" align="left" valign="top"><IMG SRC = "logo.gif" ID="Company Logo" BORDER="0"></TD>
<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
<TBODY>
<TR class=bg1 WIDTH="*">
<FONT face=arial color=red size=4 valign="top" align="left">

<MARQUEE scrollAmount=10 scrollDelay=150 loop=true width=100% height=20>
<BLINK>&URMSG</BLINK></MARQUEE></FONT></TR>
<TR class=bg1 height=25>
<TD class=bg1 width="100%">ERP Dashboard </TD></TR></TBODY></TABLE>
</BODY></HTML>

-HTMLFORM END



Hope this helps.
 
Posts: 542 | Location: Dearborn, MI | Registered: June 03, 2009Report This Post
Expert
posted Hide Post
Unless I'm completely off-base, unfortunately this suggestion does not work with B.I. Dashboards - you cannot embed any FOCUS code in the banner - it's pure HTML. Neither can you mess around with the "Message of the Day".

What you MAY be able to do is:

- Do not use the Message of the Day
- Embed JavaScript in the banner HTML to make an AJAX call to retrieve the data and then write this data into a DIV.

By the way, to embed a Dialogue Manager variable within an HTMLFORM, use !IBI.AMP.YOUR_MSG; instead of &YOUR_MSG.


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
Platinum Member
posted Hide Post
Yes, Francis , you are right on the point. Ram Prasad E s suggestion will not work for me. I am looking for a solution similar to what you have mentioned.


- Embed JavaScript in the banner HTML to make an AJAX call to retrieve the data and then write this data into a DIV.

i will try to take this suggestion and see how far I can go.

If you have a sample code on this could you please post it.


App Studio Version 8202
windows Platform
SQL Server 2008/2012
 
Posts: 183 | Location: TX | Registered: January 22, 2007Report This Post
Expert
posted Hide Post
I don't have sample code for this yet, but here's a possible way to determine what is required:

Use the Dev Studio GUI tool to build a simple HTML form using the Layout Composer tool. Create a new textbox that is populated by a dynamic focexec.

Use the HTML that is generated by this. Simplify it by removing bits at a time until the bare minimum required code is left. Put this in the Dashboard Banner HTML.

I might give this a try if I find time.


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
Master
posted Hide Post
Yes, it not possible to call an FEX directly in dashboard.
But, if its possible to call the FEX in onload event of dashboard.html file, then it should work fine.
 
Posts: 542 | Location: Dearborn, MI | Registered: June 03, 2009Report This Post
Platinum Member
posted Hide Post
That didn't seem to work.


App Studio Version 8202
windows Platform
SQL Server 2008/2012
 
Posts: 183 | Location: TX | Registered: January 22, 2007Report This Post
Expert
posted Hide Post
banner.html - B.I. Dashboard banner:

<html>
<head>
<title></title>
<script type="text/javascript" src="worp_banner.js" ></script>
</head>

<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" onload="UpdateData();" onunload="javascript:closeAllWindows();">

<table width=" 100%"  border="0" cellspacing="0" cellpadding="0" >
<tr>
<td nowrap align="right" class="bg1">
<span class="text">
<!--Links-->
<img src="clear_space.gif" width="25" height="15" border="0">
</span>
</td>
</tr>
</table>

<!-- embed data retrieved via focexec -->

<script type="text/javascript">
var cgipath = "cgipath";
var ibirls = "ibirls2";
var ibiOptions = new Array(cgipath,ibirls);
</script>

<script type="text/javascript" src="/ibi_html/javaassist/nls.js" ></script>
<script type="text/javascript" src="/ibi_html/javaassist/ibi/html/js/ibigbl.js"></script>

<table width="100%"  border="0" cellspacing="0" cellpadding="0" >
<tr>
<td align="center">

<form method="post">
<input id="edit1" style="width: 500px; border: 0px; text-align: center;" value="" datasource="message1.fex" datatype="1" sourcetype="typeFex" ibic_server="EDASERVE">
</form>

</td>
</tr>
</table>

</body>
</html>


message1.fex - FOCEXEC to retrieve data:

SET HOLDLIST = PRINTONLY
-RUN

TABLE FILE CAR
SUM
SALES
BY COUNTRY
ON TABLE HOLD AS H001
END
-RUN

TABLE FILE H001
SUM
COUNTRY
COMPUTE MESSAGE1/A100 = 'SALES WINNER: ' | COUNTRY | ' ' | EDIT(SALES);
BY HIGHEST 1 SALES NOPRINT
ON TABLE PCHOLD FORMAT XML
END
-RUN


It could probably be improved, but this proof of concept works. I started by using the Dev Studio Composer (Layout) tool to create a new HTML page. I added a form and a textbox that was dynamically filled by a focexec. Once I got this to work, I copied the HTML and stripped out all the unnecessary code. I also cleaned up the awfully generated code.

Then I edited my banner - stripping almost everything except the "links" table to create a simplified banner.html. Then I added the "onload" event attribute to the body tag. I then added the html necessary to call the focexec and populate the textbox - everything below
<!-- embed data retrieved via focexec -->


This seems to work for me - I get a message in the text-box that was created by the focexec. One thing about the focexec - it needs to pass two data elements in the XML, probably because all the included JavaScript is normally used to populate select list boxes. This could probably be improved - use AJAX instead of these JS functions, but it works. I hope I can use this idea soon.

By the way, no modern "web designer" should be using the marquee and blink html tags!


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
Platinum Member
posted Hide Post
Great Solution and it works!, We just have to make it scroll and blink and dance(:-) to make it standout on the dashboard.!
I got the marquee and blink from web, as I am not much familiar with this.


App Studio Version 8202
windows Platform
SQL Server 2008/2012
 
Posts: 183 | Location: TX | Registered: January 22, 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] Display message from focus file on Dashboard Banner

Copyright © 1996-2020 Information Builders