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     RUN FEX FROM LAUNCH PAGE

Read-Only Read-Only Topic
Go
Search
Notify
Tools
RUN FEX FROM LAUNCH PAGE
 Login/Join
 
Platinum Member
posted
I have this scenario.

1. Enter ssn on frame1.
2. Populate 3 listboxes on frame 2 based on IBI.fil technique in -HTMLFORM. (this works)
3. I want to run a fex from a button on frame2 (this is -htmlform it has an xml request developed in painter and cut and pasted into the -htmlform (in the fex run from the button on frame1)
4 the run button works when I run the form in layout painter , when I run this cut and pasted html the run button produces an error in java missing object cahar 1 line7 .

Here is html code

 


-***********************************************************************
-* THIS HTML WAS DEVELOPED IN PAINTER AND PASTED HERE
-*
-***********************************************************************
-HTMLFORM BEGIN
<HEAD>
<TITLE>HtmlPage
</TITLE>
<script id=clientEventHandlersJS type=text/javascript>
function button1_OnClick(ctrl) {
// TODO: add validation code here
OnExecute(ctrl)
}
</SCRIPT>
</HEAD>
<BODY>
<SELECT id=listbox1 style="FONT-WEIGHT: bold; FONT-SIZE: 10pt; Z-INDEX: 4; LEFT: 20px; WIDTH: 110px; FONT-FAMILY: Arial; POSITION: absolute; TOP: 120px; HEIGHT: 90px" tabIndex=1 size=2 name=FEDOPT datasource="app/1120list.fex" datatype="1" sourcetype="typeFex" IBIMR_folder="#businesskehz" ibiapp_app>
 !IBI.FIL.FEDOPT;
</SELECT>
<SPAN id=text7 style="FONT-WEIGHT: bold; FONT-SIZE: 10pt; Z-INDEX: 8; LEFT: 540px; WIDTH: 120px; FONT-FAMILY: Arial; POSITION: absolute; TOP: 100px; HEIGHT: 20px" tabIndex=11>Tax Period
</SPAN>
<SPAN id=text6 style="FONT-WEIGHT: bold; FONT-SIZE: 10pt; Z-INDEX: 7; LEFT: 270px; WIDTH: 120px; FONT-FAMILY: Arial; POSITION: absolute; TOP: 100px; HEIGHT: 20px" tabIndex=10>Tax Period
</SPAN>
<SPAN id=text5 style="FONT-WEIGHT: bold; FONT-SIZE: 10pt; Z-INDEX: 6; LEFT: 430px; WIDTH: 80px; FONT-FAMILY: Arial; POSITION: absolute; TOP: 100px; HEIGHT: 20px" tabIndex=9>Mits
</SPAN>
<SELECT id=listbox2 style="FONT-WEIGHT: bold; FONT-SIZE: 10pt; Z-INDEX: 4; LEFT: 170px; WIDTH: 230px; FONT-FAMILY: Arial; POSITION: absolute; TOP: 120px; HEIGHT: 90px" tabIndex=2 size=2 name=MOINC>
 !IBI.FIL.MOINCOME;
</SELECT>
<SELECT id=listbox3 style="FONT-WEIGHT: bold; FONT-SIZE: 10pt; Z-INDEX: 4; LEFT: 430px; WIDTH: 250px; FONT-FAMILY: Arial; POSITION: absolute; TOP: 120px; HEIGHT: 90px" tabIndex=3 size=2 name=FRANCHISE>
 !IBI.FIL.FRANCHIS;
</SELECT>
<SPAN id=text1 style="FONT-WEIGHT: bold; FONT-SIZE: 10pt; Z-INDEX: 4; LEFT: 20px; WIDTH: 110px; FONT-FAMILY: Arial; POSITION: absolute; TOP: 80px; HEIGHT: 40px" tabIndex=4>Select Federal End Date
</SPAN>
<SPAN id=text2 style="FONT-WEIGHT: bold; FONT-SIZE: 10pt; Z-INDEX: 4; LEFT: 200px; WIDTH: 180px; FONT-FAMILY: Arial; POSITION: absolute; TOP: 60px; HEIGHT: 20px" tabIndex=5>
<DIV>Select Missouri Income :
</DIV>
</SPAN>
<SPAN id=text3 style="FONT-WEIGHT: bold; FONT-SIZE: 10pt; Z-INDEX: 4; LEFT: 460px; WIDTH: 180px; FONT-FAMILY: Arial; POSITION: absolute; TOP: 60px; HEIGHT: 20px" tabIndex=6>
<DIV>Select Franchise:
</DIV>
</SPAN>
<INPUT language=java_script id=button1 style="FONT-WEIGHT: bold; FONT-SIZE: 10pt; Z-INDEX: 4; LEFT: 550px; WIDTH: 110px; FONT-FAMILY: Arial; POSITION: absolute; TOP: 230px; HEIGHT: 30px" onclick=button1_OnClick[this) tabIndex=7 type=button value="Run Repport" name=button1 requests_list="0">
<SPAN id=text4 style="FONT-WEIGHT: bold; FONT-SIZE: 10pt; Z-INDEX: 5; LEFT: 170px; WIDTH: 80px; FONT-FAMILY: Arial; POSITION: absolute; TOP: 100px; HEIGHT: 20px" tabIndex=8>Mits
</SPAN>
<xml id=ibi_requests>
<requests>
<request requestid="0" sourcetype="typeFex" targettype="1" targetname="_blank" ibif_ex="app/1120repo.fex" IBIMR_folder="#businesskehz" ibiapp_app="" >
<variable field="" file="" desc="" datatype="0" operation="" default=" " name="FEIN" accept="0" type="default" select="0" controltype="7">
</variable>
<variable field="" file="" desc="" datatype="0" operation="" default=" " name="MOINCOME" accept="0" type="default" select="0" controltype="7">
</variable>
<variable field="" file="" desc="" datatype="0" operation="" default=" " name="FRANCHIS" accept="0" type="default" select="0" controltype="7">
</variable>
</variables>
</request>
</requests>
</xml>
</BODY>
-HTMLFORM END

This message has been edited. Last edited by: secret,
 
Posts: 103 | Location: ricmmond va | Registered: September 30, 2004Report This Post
Expert
posted Hide Post
Secret,

Work through it logically.

You have a web page that has a button that has an onclick event attached to it. This onclick event calls a javascript function that exists within your HTML. In turn this function calls the function "OnExecute(ctrl)" - and that's where you have a problem, where is that function? You do not have any javascript modules included within your HTML - do you expect it to find it itself?

The trouble with cutting and pasting code from some of the painter apps is that you are not shown all of the code required to run that particular process. This is to help with understanding the process(?!). To get all the code required, save your process and then open it in an editor then cut and paste your code.

With writing applications that rely upon HTML, XML, JavaScript etc. comes the responsibility of learning basic skills to allow you to interpret errors and fix them.

With the advent of "code writers" (that's what the painter apps are) came the de-skilling of the developer community and that is a real problem. We end up with "bloat ware" and the knock on effects that causes.

I'm not having a knock at you personally in this, there are many in the same position as you where the pre-requisite training is not forthcoming.

To help, try looking at the "Ugly JavaScript" Manual (search on Google) and the W3c site(s) for help in understanding HTML etc.

Oh, and good luck!! Smiler

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
Virtuoso
posted Hide Post
Tony,

Excellent points.

But I do hope your not suggesting that the 70k+ of js that WF wraps around the painter code is bloat? Music


Alan.
WF 7.705/8.007
 
Posts: 1451 | Location: Portugal | Registered: February 07, 2007Report This Post
Guru
posted Hide Post
Tony,

I agree with you. However, HTML, XML, JavaScript etc. are not my strong points but I can code the queries to do just about anything I want. That's where it's great to have a partner that is strong in those areas.


Glenda

In FOCUS Since 1990
Production 8.2 Windows
 
Posts: 301 | Location: Galveston, Texas | Registered: July 07, 2004Report This Post
Platinum Member
posted Hide Post
Tony:

Thank you for your response. I am not sure which IBI javascript module to include. How would I find out where the onexecute function is. This code works directly under developer studio, but when I paste it into the fex it doesn't find it.
 
Posts: 103 | Location: ricmmond va | Registered: September 30, 2004Report This Post
Expert
posted Hide Post
Alan,

IB JavaScript - bloatware? Perish the thought Cool

Secret,

The JS modules are generally contained in the ibi_html/javaassist/js folder (I think). The main ones are IBIRLS.js (vsn <7.n) IBIRLS2.JS [vsn >=7.n) but these would normally be inserted for you when you create the HTML file in painter.

Try saving the code and then looking at it using notepad outside of WF (if you can) and you will see lots of code you didn't know was there.

Good luck

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
Glenda,

HTML, XML and javascript may not be your strong points but I am sure (by inference) that you have had a dabble and understand the rudementary relationship between these components and WF? That is all I am suggesting that WF developers require and then, at least, you will have the knowledge to be able to understand where to start looking and what there should be within your code?

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
Virtuoso
posted Hide Post
secret

As Tony says there is more than one module. When you save an html file from the layout painter, the scripts are all there, but not quite all in one place, with scripts calling other script.

Or, when you run from the layout painter, view source and see the parts added by webFOFOCUS.

It is not totally straightforward though, so take care.


Alan.
WF 7.705/8.007
 
Posts: 1451 | Location: Portugal | Registered: February 07, 2007Report This Post
Expert
posted Hide Post
One of the other "biggies" is IBIGBL.js. This combined with IBIRLS.js provide most - but not all - of the js functions that might be required in your HTML pages.

Alan is correct in advising care and this underlines my point(s) above. Understand the relationship between the required components and that will make you more effective in problem determination if not in problem resolution Smiler

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
Platinum Member
posted Hide Post
Tony,

Thank you again. I am off until Monday when I will try this out.
 
Posts: 103 | Location: ricmmond va | Registered: September 30, 2004Report This Post
Guru
posted Hide Post
If your are trying to call button1_OnClick() from within a frame you will receive the "object not found" error because the browser is looking for the code within the frame. To access javascript functions that appear in the main body of the page, then appent the function name with top. or parent. - so the call would become parent.button1_OnClick().

Beware of using top., it will work fine as long as you don't try and embed the main page into another document (ala Dashboard). if you do then it will be pointing to the wrong place.

Hope this helps

Stu


WebFOCUS 8.2.03 (8.2.06 in testing)
 
Posts: 253 | Location: Melbourne, Australia | Registered: February 07, 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     RUN FEX FROM LAUNCH PAGE

Copyright © 1996-2020 Information Builders