You have two options when doing this: either embed the HTML code inside the WebFOCUS code or reference an existing HTML page stored elsewhere.
Syntax for inline HTML code:
Syntax for referencing separate HTML code:
You can see your Information Builders documentation for more details on the -HTMLFORM command. I have seen both of the above options in use at client sites and only recently encountered an issue that would cause me to suggest one approach over the other.
If you embed the HTML form inside the 4GL code using the BEGIN and END tags, the WebFOCUS pre-processor for Dialogue Manager symbolic variables will read that HTML code. If you have ampersand variables referenced in the HTML form, you run the risk of having substitution happen when you do not want it. Then, you need to take extra steps to make sure your variables are not evaluated and changed to their literal values. For example, if your HTML contains a servlet call with variables, those will get evaluated and changed (not what you want to happen).
If on the other hand your program just references the HTML form stored in an HTML file, WebFOCUS does not do the symbolic variable evaluations. Problem avoided.
So here is my advice. If you need to dynamically build an HTML form, then putting it inline and using Dialogue Manager is your best approach. However for static HTML forms, you should always put the HTML code elsewhere and reference it by name inside your WebFOCUS code.
Another note: I believe that as of the latest 7.6 release, your HTML form file must be on the WebFOCUS Report Server in the app path and not in the Managed Reporting Environment. When searching for the referenced HTML form file, WebFOCUS is currently only searching the WFRS applications and not looking in MRE (I have asked IBI for an enhancement to the command).


0 comments:
Post a Comment