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]Pass values from HTML page to Procedure

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[Solved]Pass values from HTML page to Procedure
 Login/Join
 
Platinum Member
posted
Hi,

I have got a HTML page where i would be entering 3 input's. I need to pass these 3 parameters to one procedure. Could you please help me on how to do this.

This message has been edited. Last edited by: Vinay Kumar,


WebFOCUS 7.6.4, Mainframe Focus
Windows XP, All Output Formats
 
Posts: 135 | Registered: November 30, 2010Report This Post
Expert
posted Hide Post
Please read the documentation - this is one of the most basic things you can do with WebFOCUS: create an HTML form that submits a WebFOCUS report, passing form object values.


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
Francis, thanks for the reply.

I am a beginner in Web Focus. If you could please pass on the link where i can find HTMLFORM tutorials it would be great.


WebFOCUS 7.6.4, Mainframe Focus
Windows XP, All Output Formats
 
Posts: 135 | Registered: November 30, 2010Report This Post
Member
posted Hide Post
You can use the &variable, where variable is the name of the input u want to pass in the procedure to get the values passed on from the HTML


WebFOCUS 7.6
Windows, All Outputs
 
Posts: 11 | Registered: November 17, 2010Report This Post
Platinum Member
posted Hide Post
The below is one of the inputs code in HTMLFORM. The name of the input is "calendar1".

<INPUT id=calendar1 name=calendar1 ibiformat="YMD" calendardatatype="1" calendardata="0/0/-10;0/0/10" elementtype="14">


In Procedure, i have tried SET VARIABLE=&calendar1;

Is it the right way? If not please suggest me the correct way.

This message has been edited. Last edited by: Vinay Kumar,


WebFOCUS 7.6.4, Mainframe Focus
Windows XP, All Output Formats
 
Posts: 135 | Registered: November 30, 2010Report This Post
Expert
posted Hide Post
Unfortunately, you need to read up on Dialogue Manager as well. Assuming you used the HTML Composer to create your page and your WebFOCUS program contained the variable &calendar1, when you run your page and click submit, your &calendar1 variable will already be populated with a date in YMD order.

Put this at the beginning of your program:

-? &
-EXIT  
Your program will run and you will see a list of all the variables being passed to your program from the launch page.


Ginny
---------------------------------
Prod: WF 7.7.01 Dev: WF 7.6.9-11
Admin, MRE,self-service; adapters: Teradata, DB2, Oracle, SQL Server, Essbase, ESRI, FlexEnable, Google
 
Posts: 2723 | Location: Ann Arbor, MI | Registered: April 05, 2006Report This Post
Platinum Member
posted Hide Post
Ginny

Could you please give me simple example so that i can understand better.


WebFOCUS 7.6.4, Mainframe Focus
Windows XP, All Output Formats
 
Posts: 135 | Registered: November 30, 2010Report This Post
Platinum Member
posted Hide Post
DevStudio HTML Composer does this for you. Give it a try. If you want to hand code HTML, the calling convention and required parameter names (IBIC_server, etc.) are all documented.

In addition, you need to read up on WebFOCUS syntax. The SET command is used for setting various run-time switches (my fav: SET ALL=ON).
Setting variables is done with:
-SET &VAR... = expression ;
But you do not need to do the set because it is already a variable from the WFServlet?IBIF_ex call.


Brian Suter
VP WebFOCUS Product Development
 
Posts: 200 | Location: NYC | Registered: January 02, 2007Report This Post
Platinum Member
posted Hide Post
Brain, thanks for the suggestion.

I have been working on report generations, recently started working on HTMLFORMS.
Could you pls help me in finding the precise document, which helps me in understanding HTMLFORMS better.


WebFOCUS 7.6.4, Mainframe Focus
Windows XP, All Output Formats
 
Posts: 135 | Registered: November 30, 2010Report This Post
Expert
posted Hide Post
Depending on which release of 7.6 you are using since you don't specify in your signature, the manual and product name changes.

In the earlier releases, the product was called the HTML Layout Painter and was documented in the Developing Applications with Graphical Tools manual.

In the later releases (7.6.9 I think), its name changed to the HTML Composer and it has its own manual called Designing a User Interface
for a Web Application With
the HTML Composer.

If you have further questions on documentation, you can check out the documentation link in the upper righthand corner of this page.

Good luck.


Ginny
---------------------------------
Prod: WF 7.7.01 Dev: WF 7.6.9-11
Admin, MRE,self-service; adapters: Teradata, DB2, Oracle, SQL Server, Essbase, ESRI, FlexEnable, Google
 
Posts: 2723 | Location: Ann Arbor, MI | Registered: April 05, 2006Report This Post
Virtuoso
posted Hide Post
If you're not using the Composer or have to code it manually for some reason, then the way to do this is to have a Form in your htmlpage with an action to run the WFServlet. All fields you include in your form will be transported automatically to WebFOCUS as & variables.


GamP

- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
 
Posts: 1961 | Location: Netherlands | Registered: September 25, 2007Report This Post
Platinum Member
posted Hide Post
Gamp,
what would WFServlet does? Could you pls explain me little bit about the servlet.

Does the URL shows the variable passing from form to Procedure?


WebFOCUS 7.6.4, Mainframe Focus
Windows XP, All Output Formats
 
Posts: 135 | Registered: November 30, 2010Report This Post
Virtuoso
posted Hide Post
WFServlet is the webfocus client. It's the piece between the browser and the report server. Whether the url shows the variables or not depends on the method specified with the form tag. The value for that is either GET or POST, and I always forget which one shows the variables and which one doesn't. The one that does show is limited to a certain IE defined maximum size. The one that doesn't is not limited.


GamP

- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
 
Posts: 1961 | Location: Netherlands | Registered: September 25, 2007Report This Post
Platinum Member
posted Hide Post
Gamp,

I have created a form using HTML Layout Painter and the form tag looks like
<FORM id=form2 name=form2 action=/ibi_apps/WFServlet method=post>


some input fields

</FORM>


Could you please tell me whether the form tag is correct to pass the value to fex file.


WebFOCUS 7.6.4, Mainframe Focus
Windows XP, All Output Formats
 
Posts: 135 | Registered: November 30, 2010Report This Post
Platinum Member
posted Hide Post
Gamp,

any suggestions on the above post?


WebFOCUS 7.6.4, Mainframe Focus
Windows XP, All Output Formats
 
Posts: 135 | Registered: November 30, 2010Report This Post
<JG>
posted
quote:
some input fields


Any input fields on the form will get passed to the WebFOCUS request.

do as Ginny suggests and add
-? &
-EXIT

to the top of your focexec

it will display all variables and their assigned values

quote:
GET or POST


GET does POST does not.
 
Report This Post
Platinum Member
posted Hide Post
JG,
I did what Ginny has suggested but i couldn't able to see my inputs passing to procedure.

I have been searching for correct code, but couldn't able to get it.


WebFOCUS 7.6.4, Mainframe Focus
Windows XP, All Output Formats
 
Posts: 135 | Registered: November 30, 2010Report This Post
Platinum Member
posted Hide Post
I apoligies for the above post.
Finally i could able to pass my input from HTMLFORM to procedure.

When i displaying the input in HEADER, it is displaying fine but when i am using it in define for some computations it is displaying wrong input.

Input: 2011/01/31

DEFINE FILE TEST
TESTCAL/YYMD=&calendar1;
END
TABLE FILE TEST
PRINT TESTCAL
END
FIN

The output it is displaying is 1901/03/05.

What might have went wrong?


WebFOCUS 7.6.4, Mainframe Focus
Windows XP, All Output Formats
 
Posts: 135 | Registered: November 30, 2010Report This Post
<JG>
posted
quote:
What might have went wrong?

Invalid format for the input date

Try
 
-SET &calendar2=EDIT('&calendar1.EVAL','9999$99$99');
DEFINE FILE CAR
TESTCAL/YYMD=&calendar2;
END
TABLE FILE CAR
PRINT TESTCAL
BY COUNTRY
END 
 
Report This Post
Virtuoso
posted Hide Post
quote:
Input: 2011/01/31

DEFINE FILE TEST
TESTCAL/YYMD=&calendar1;
END
TABLE FILE TEST
PRINT TESTCAL
END

Try
DEFINE FILE TEST
TESTCAL/YYMD=&calendar1.QUOTEDSTRING;
END
or
DEFINE FILE TEST
TESTCAL/YYMD='&calendar1';
END


Alan.
WF 7.705/8.007
 
Posts: 1451 | Location: Portugal | Registered: February 07, 2007Report This Post
Platinum Member
posted Hide Post
Thing of your original input:
2011/01/31
That is an integer expression 2011 divided by 1 and then divided by 31. The result will be taked as the number of days since jan 1st 1901.
The assignment operator is nice about NEW dates on the left and alphas on the right. So you should try
TESTCAL/YYMD='&calendar1';


Brian Suter
VP WebFOCUS Product Development
 
Posts: 200 | Location: NYC | Registered: January 02, 2007Report This Post
Master
posted Hide Post
With due respect Vinay, it might be helpful if you took some of the courses offered by Information Builders. Some of the questions you are asking are extremely basic, and if you don't have a handle on those your chances of progressing at a reasonable rate are pretty slim. I'm an old Focus hand, but new to WebFocus and I have found these courses (I've taken 4 so far) to be invaluable - I've even encountered some new-to-me features that have been included with the old version of Focus I've been using for the past 10 years.


WebFOCUS 7.7.05 Windows, Linux, DB2, IBM Lotus Notes, Firebird, Lotus Symphony/OpenOffice. Outputs PDF, Excel 2007 (for OpenOffice integration), WP
 
Posts: 674 | Location: Guelph, Ontario, Canada ... In Focus since 1985 | Registered: September 28, 2010Report This Post
Platinum Member
posted Hide Post
Thanks for the suggestion George and even i was thinking about that. Could you please share the link where i can take the courses.


WebFOCUS 7.6.4, Mainframe Focus
Windows XP, All Output Formats
 
Posts: 135 | Registered: November 30, 2010Report This Post
Master
posted Hide Post
http://education.informationbuilders.com/course-list/


WebFOCUS 7.7.05 Windows, Linux, DB2, IBM Lotus Notes, Firebird, Lotus Symphony/OpenOffice. Outputs PDF, Excel 2007 (for OpenOffice integration), WP
 
Posts: 674 | Location: Guelph, Ontario, Canada ... In Focus since 1985 | Registered: September 28, 2010Report This Post
Platinum Member
posted Hide Post
Thanks George.

Are there any recorded sessions available in the format of DVD in the market?


WebFOCUS 7.6.4, Mainframe Focus
Windows XP, All Output Formats
 
Posts: 135 | Registered: November 30, 2010Report This Post
Master
posted Hide Post
I don't work for Information Builders, Vinay ..... you should contact them (look on their website) for information on what they have available.

WebFocus is a very expensive product and if your employer can afford to buy it he/she can certainly afford to send you to appropriate training classes. I work for what is probably the smallest customer of Information Builders - only 30 people in the whole company, and I am the entire IT department - but somehow they come up with the funds to send me for training, so your employer shouldn't have any problems.


WebFOCUS 7.7.05 Windows, Linux, DB2, IBM Lotus Notes, Firebird, Lotus Symphony/OpenOffice. Outputs PDF, Excel 2007 (for OpenOffice integration), WP
 
Posts: 674 | Location: Guelph, Ontario, Canada ... In Focus since 1985 | Registered: September 28, 2010Report This Post
Platinum Member
posted Hide Post
Thanks George.

I have contacted IB people, they have sent me links which has recorded sessions.


WebFOCUS 7.6.4, Mainframe Focus
Windows XP, All Output Formats
 
Posts: 135 | Registered: November 30, 2010Report 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]Pass values from HTML page to Procedure

Copyright © 1996-2020 Information Builders