creating a rich internet application using the html composer · application. rich internet...

18
Creating a Rich Internet Application Using the HTML Composer By David Glick A Rich Internet Application (RIA) enables you to create an interactive Web page experience inside the browser. Using Rich Internet Applications, you can generate the exact look and feel of a Windows-based graphical user interface in your Web applications. Rich Internet Applications provide rich and powerful graphics and themes. You may set a Rich Internet Application theme and animation properties for objects in the Design tab of HTML Composer. Additionally, you may convert an existing page to a Rich Internet Application or create a new page as a Rich Internet Application. Rich Internet Application development is a production feature of WebFOCUS release 7.7.01. The process of creating a Rich Internet Application with the HTML Composer consists of the following steps: Enabling a RIA theme from the document properties of the HTML page. Note: When Rich Internet Application development is enabled, the Rich Internet Application Components toolbar is added to the HTML Composer. The Window and Accordion Control options are available from the RIA Components toolbar. These components are additional controls available only when a RIA theme is enabled. The traditional controls, buttons, tabs, and so on, all inherit a Rich Internet Application look and feel when a RIA theme is applied. A Rich Internet Application Window component enables you to create movable and resizeable windows on your HTML page that function as a container for other objects. A Rich Internet Application Accordion Control component enables you to create multiple pages within the control that you can scroll through, each containing objects. Setting the animation properties for the objects on the HTML page. You may convert an existing HTML page to a Rich Internet Application by applying a RIA theme to the existing non-RIA page. The entire page will be updated with the Rich Internet Application

Upload: others

Post on 22-May-2020

8 views

Category:

Documents


0 download

TRANSCRIPT

Creating a Rich Internet Application Using the HTML Composer

By David Glick

A Rich Internet Application (RIA) enables you to create an interactive Web page experience inside the browser. Using Rich Internet Applications, you can generate the exact look and feel of a Windows-based graphical user interface in your Web applications. Rich Internet Applications provide rich and powerful graphics and themes. You may set a Rich Internet Application theme and animation properties for objects in the Design tab of HTML Composer. Additionally, you may convert an existing page to a Rich Internet Application or create a new page as a Rich Internet Application. Rich Internet Application development is a production feature of WebFOCUS release 7.7.01.

The process of creating a Rich Internet Application with the HTML Composer consists of the following steps:

• Enabling a RIA theme from the document properties of the HTML page. Note: When Rich Internet Application development is enabled, the Rich Internet Application Components toolbar is added to the HTML Composer. The Window and Accordion Control options are available from the RIA Components toolbar. These components are additional controls available only when a RIA theme is enabled. The traditional controls, buttons, tabs, and so on, all inherit a Rich Internet Application look and feel when a RIA theme is applied.

• A Rich Internet Application Window component enables you to create movable and resizeable windows on your HTML page that function as a container for other objects.

• A Rich Internet Application Accordion Control component enables you to create multiple pages within the control that you can scroll through, each containing objects.

• Setting the animation properties for the objects on the HTML page.

You may convert an existing HTML page to a Rich Internet Application by applying a RIA theme to the existing non-RIA page. The entire page will be updated with the Rich Internet Application

look and feel. If there is any reason to preserve the old page, you will need to create a copy of it before saving the converted page.

1. Open an existing HTML file in the HTML Composer.

2. Select DOCUMENT from the Properties window dropdown list.

The available properties for the document object appear.

3. Select a theme from the RIA Theme dropdown list.

The RIA theme is applied to all components on the page. You may need to resize some of your components.

4. Save and run the HTML page to see the RIA.

Screen 1

To create a Rich Internet Application from scratch, the steps are a little different.

1. Create a new HTML file with the HTML Composer.

2. Select DOCUMENT from the Properties window dropdown list.

3. Select a theme from the RIA Theme dropdown list.

The RIA Components toolbar is added to the HTML Composer.

Screen 2

4. Add objects to the layout, such as buttons and images, from the Components toolbar.

5. Optionally, add RIA-specific objects to the layout, such as windows and accordions, from the RIA Components toolbar.

6. Set the animation properties for the objects with the Animation Properties dialog box.

• Select an object from the Design tab of the HTML Composer.

• Click the Animation Properties ellipsis button from the Properties window. The Animation Properties dialog box opens.

Set the animation properties for the location, size, and/or opacity for the selected object.

7. Save and run the HTML page to see the Rich Internet Application.

Adding window and accordion controls allow other objects to sit within these objects. To accomplish this, use the following steps:

8. Select the Window or Accordion button from the RIA Components toolbar. The cursor changes into a crosshair.

9. Click and drag the crosshair to create the window or accordion and adjust it to the size you want.

10. Add an object, as a child, within the window or accordion component.

• Select an object from the Components toolbar from the Design tab of the HTML Composer.

• Left-click and drag the selected object component from the toolbar inside of the window or accordion RIA component.

• Tip: If you have other objects on your Design canvas, you may press and hold the Alt key, left-click, and drag that object onto a RIA parent component.

• Release the mouse and resize the object inside your component.

When adding animation, the dialogue you see on Screen 3 appears.

Screen 3

There are three types of animation: location, size, and opacity. Any object on a Rich Internet Application page may use animation, and any object may use multiple animation types.

Location animation allows an object to change location at runtime. You specify the From Position and the To Position. You may set the speed and what control will activate this animation. If you want to reverse the animation on a second click of the control used to activate the animation, you may check the checkbox.

Similarly, size animation allows the object to change size at runtime, and opacity animation allows the object to blink, pulsate, fade in, or fade out.

This is a really cool feature of release 7.7.01 so I suggest you try it out.

WebFOCUS 7.7 MR Default Change to Not Show Standard Reports and Other Files By Susan Trommer

Within the Managed Reporting environment, each Standard Report has a property that controls whether a Standard Report is accessible to users from the MR tree and whether an Other File, consisting of a style file (CSS or STY), is accessible to users from the report development tools. The purpose of this property is to enable developers to hide Standard Reports (reports, forms, documents) or style files (Other Files) from users while they are being developed and when they are to be only referenced for environment setup or navigated to from a link in a form or a report. In Release 7.6 and earlier releases the property name is “Show on User’s list,” which is selected by default and makes a Standard Report or Other File immediately accessible to users who are authorized to access the content of the domain in which the report is created. It is the responsibility of the user developing the report to know the context in which the Standard Report or Other File will be used and deselect the “Show on User’s list” property when it should not be accessible to users from the MR tree. Screen 1 shows the Release 7.6 Dashboard Standard Report Properties dialog with “Show on User’s list” property selected.

Screen 1: Release 7.6 Dashboard Standard Report Properties

To create a Standard Report with InfoAssist (Screen 2), Power Painter or Advanced Graph Assistant specifying to not show a report to users, it takes a two-step process. The report has to first be saved and then the developer needs to exit the tool and select the report’s Properties option to uncheck the “Show on User’s list” property. This is an obvious usability issue needing review and improvement.

Screen 2: InfoAssist Save A review of customer support cases – both problems and new feature requests – and Focal Point Forum posts concluded that the default setting should be changed to not show Standard Reports and Other Files. The two most common explanations provided to justify the default behavior change are as follows: 1. Most users do not finish creating or coding a report the first time the report is saved. 2. A developer may forget to deselect “Do not show on User’s list,” thus prematurely making a report accessible to users. The default property setting change is implemented in Release 7.7 by changing the “Show on User’s list” property to “Do not show on User’s list.” There are no considerations for existing procedures because the same MR repository internal flag value, “hidden,” is used. The hidden flag value specifies the Standard Report is not to be displayed in the MR tree, and Other Files that are style files (CSS or STY) will not be accessible to users within the reporting tools that support the selection of style files in an MR domain. The “Do not show on User’s list” change is implemented for the following:

Dashboard Standard Report and Other Files Properties (Screen 3) Developer Studio Managed Reporting – Standard Report and Other Files create, save and

properties dialogs Web reporting tools create and save dialogs that display property options. For save dialogs

that do not display property options, the default property settings are specified with the save request.

The property change is not implemented for the MR Applet Interface. The MR Applet Standard Report and Other Files properties dialog will display the “Show on User’s list” property label with the checkbox selected when the “hidden” flag is not stored in the MR repository metadata for the Standard Report or Other File. Also, the Applet Text Editor Save dialog and the MR Applet Publish Utility will have the “Show on User’s list” property selected by default.

Screen 3: Release 7.7 Dashboard Standard Report Properties As with all changes, this one may take some time to communicate, understand and remember. So if you are evaluating, or have upgraded to Release 7.7.01, and create a new Standard Report but don’t see it list when accessing Managed Reporting as a user with Analytical User or lower capability role, check the properties setting of the Standard Report to verify if the “Do not show

on User’s list” is selected. The same goes for a style file (CSS or STY) that is not listed in the reporting tools that support the selection of style files from an MR domain.

Tips and Techniques Wanted for Focal Point

WebFOCUS and iWay developers have an opportunity to show off their skills by contributing articles with tips and techniques to our Focal Point website. Focal Point is Information Builders’ developer community, which includes message boards, a Tips and Techniques section and links to various resources.

Do you have a problem you solved and want to share it with your fellow developers in the form of an article? You may do so by submitting an article for publication on our Focal Point Tips and Techniques section. Visit the site http://www.informationbuilders.com/support/developers/index.html to find out how.

To give you a flavor of what you will find in Tips and Techniques, here are summaries to several recent articles written by users of Information Builders technology:

What Is WebFOCUS?

Grzegorz Swietlik, a freelance IT consultant and software developer, answers this question from a developer's perspective by going in depth into the features of Information Builders’ reporting engine.

WebFOCUS MetaDATEs

John Kutasz from US Bank delves into the topic of DATE functions, and shares tips on how to get the most out of them when running reports with predictable date ranges.

CTRAN Without Pain

In this piece, Francis Mariani answers the question, “Can you use CTRAN without having to figure out the Hex value (which is different for ASCII and EBCDIC)?”

Customer Friendly Self-Service

Harry Cleveland, Assistant Director of Enterprise Reporting Services from Temple University, explains how WebFOCUS self-service applies to allowing casual users access to many different directories, datasets and applications with customer-friendly interfaces.

Visit the Tips and Techniques http://www.informationbuilders.com/support/developers/index.html site to read these articles and many more. And, remember, if you have a technique to share, the Focal Point developer community welcomes your contribution.

Troubleshooting Open Portal Services

By Gil Rodriguez WebFOCUS Open Portal Services provides a set of components that allows WebFOCUS to integrate quickly and extend WebFOCUS Business Intelligence capabilities to end users within an existing EIP framework. Open Portal Services is packaged as part of the Managed Reporting license agreement and, therefore, does not require a separate license. WebFOCUS Open Portal Services has support for many of the leading portal products such as SharePoint, IBM WebSphere, and SAP, as well as JSR-168 compliant portals such as JetSpeed, JBOSS, and Vignette. In this article, I’ll provide some tips for troubleshooting some of the more common Open Portal Services errors when integrating with supported portals. 1. Login Failed

• If you get a “Login Failed” error, you must verify the following:

• That the Portal Login User ID matches a User ID in the Managed Reporting Repository. • That Trusted Key (if applicable) matches the WebFOCUS Client IBIMR_TRUSTED_KEY

value found under ...\client\wfc\etc\cgivars.wfs

• If the PORTAL_SIGNON_TRIM_DOMAIN parameter value matches your configuration. 2. Access Denied If you get an “Access Denied” error, here’s what you need to verify:

• That the Portal IP address is properly defined in the RESTRICT_WOAS_TO_IP parameter.

• That the WebPart in “SharePoint” is not configured as an isolated WebPart. Requests coming from an isolated WebPart will be made from the user’s client machine as opposed to the SharePoint Portal machine whose IP address is defined in the RESTRICT_WOAS_TO_IP parameter.

• If the user logged into the portal is a user with these roles: No Privileges, Group Authorization Manager or Security Object Manager User. Users with these types of roles are denied access to any of the Open Portal Services components.

3. HTTP 404 Error

When you get an “HTTP 404 Error,” you need to verify if the USE_GATEWAY parameter is set correctly. YES for JSR168 compliant portals (if WebFOCUS Client and the Portal machine reside on different machines) or NO for Non-JSR168 portals such as SharePoint. The USE_GATEWAY is set to TRUE by default in the product. 4. “Loading… Please Wait!”

You will get a “Loading… Please wait!” message if one of the following is occurring:

• A portlet attempts to open a non-existing socket. Eventually, it will time out. • Check the hostname, port and context path defined for the portlet. • Run the wfsysinf.jsp utility on the portal to see which WebFOCUS Client the gateway is

actually pointing to. To further troubleshoot Open Portal Services issues, you can look at HTTP traces, Dashboard, Gateway and Application server traces or logs. To enable Gateway traces, you can set the debug parameter to “on” and specify log file location in the gateway’s web.xml file. The gateway will then need to be re-deployed. In Release 7.7.02, Open Portal Services traces will be enabled from the WebFOCUS Administration Console. NOTE: As of Release 7.7.01, various portal parameters such as USE_GATEWAY, RESTRICT_WOAS_TO_IP and PORTAL_SIGNON_TRIM_WINDOWS_DOMAIN are now configurable via the Portal link in the Configuration section of the WebFOCUS Administration Console. For more information, see our WebFOCUS Open Portal Services Administration Guide.

WebFOCUS Map Viewer Gets a New Look By Mithu Datta The new mapping interface for WebFOCUS will be a leap forward from the currently available Java-based WebFOCUS Map Viewer. We are currently testing this new Map Viewer, which is commonly referred to as WebFOCUS Flex Viewer and was developed using the Adobe Flex 1.5 Development Environment and ESRI Flex API 1.0. Flex is a free, highly productive open source framework for developing cross-platform Rich Internet Applications. As with the current Map Viewer, this new version uses an adapter to integrate the mapping capabilities of ESRI with the Information Builders WebFOCUS line of products. It is a perfect marriage of business intelligence with geo-spatial intelligence. The WebFOCUS Flex Viewer will help building business intelligence solutions that result in quicker and more complete analyses of different types of data. You can distribute analysis results using a Web 2.0-style interface (Screen 1) in the form of interactive maps as well as traditional business reports and charts. The goal is to enable you to make more informed and timely decisions.

Screen 1 Leveraging ESRI’s open source framework developed in Flex for Web mapping (Screen 2), we have added WebFOCUS tools to take advantage of Information Builders’ robust reporting capabilities. Display of information is bidirectional. There are three conduits for display in this mapping interface – reports, maps and identifies.

Screen 2

Screen 3 Reports are triggered using a location-based query, which is passed on to the Reporting Server and served as stylized reports. These reports provide drill-down options to communicate back to the mapping interface to display information in a different format. This means the map displays the information visually. In addition, map reports can be triggered directly from within the map itself. After the location-based query, the map communicates with the Reporting Server to get data available in any format, and displays it on the map visually using colors, symbols, pictures, etc. The identify reports are single location-based queries. Once the user clicks on a particular location, the map receives information back from the reporting server to display the information in little

contextual windows right on the map. These may include, but are not limited to, callouts and hover-overs. Since we are utilizing Adobe’s Flex Framework, we can display information in a more intuitive and visual way than ever before. The first release of the software is targeted at the customers of our Law Enforcement Analytics customers. Customers have expressed much interest in implementing this new rich Web mapping interface, which is a perfect merger of design, style, business and locational analysis. We have just ended the first phase of development of this application. A lot of new feature requests from customers are coming through, which we are prioritizing and will make available in the next phases of development. We are actively looking for suggestions for naming this new Map Viewer and any suggestions will be highly appreciated. Please forward all your suggestions and inquiries to [email protected]. Insensitivity, Not a Bad Thing for Data By Noreen Redden As we all know, FOCUS began its life on the IBM Mainframe, a very sensitive world. If we look at code pages, there is a major difference between the binary value of A and a. Some application developers took advantage of that fact, using upper and lowercase letters to represent different codes. Maintenance procedures could request information in mixed-case and test as needed. Report requests would likewise compare in a sensitive mode and differentiate between cases. Similarly, sorts would see no correlation between uppercase and lowercase letters. Now enter the new world of case insensitivity. When I search on Information Builders’ internal support site for problems to do with FRL, for example, I don’t worry about case. Typically, I put everything in lowercase, and the search engine retrieves the data insensitively, everything with FRL, Frl, frl, etc. Relational engines allow the DBA to specify whether data should be selected sensitively or insensitively. If I ask Excel to sort the letters: a,b,B,C,c , the result is a,b,B,C,c. The letters are given the same weight, so b is less than C and is also less than c, although within that weight, Excel will sort on retrieval sequence. So, what happens when FOCUS (sensitive as it is), meets Oracle insensitivity? Usually, less data than I anticipated or required. Consider the following: TABLE FILE EMPSQL PRINT LN FN PAY WHERE LN EQ 'deFazio' END

I see from the traces that the following SQL is generated: SQL SELECT T1."LN",T1."FN“,T1. "PAY" FROM master.dbo.EMPSQL T1 WHERE (T1. "LN" = 'deFazio‘); The following values for LN are returned from SQL: DEFAZIO ANTHONY 10,000 deFazio Anthony 10,000 DeFazio Anthony 10,000 But, my report only shows: deFazio Anthony 10,000 What happened? Well, insensitive SQL returned three rows, but when the WHERE test was re-applied by sensitive FOCUS, only one of those rows in the answer set passed the WHERE. Sure, there are ways to get what you want or need. Use the function UPCASE. -SET &OUTFMT= ''''| 'A' | &VAR.LENGTH | ''''; -SET &UVAR=UPCASE(&VAR.LENGTH, & VAR , &OUTFMT.EVAL ); TABLE FILE EMPSQL PRINT LN FN PAY WHERE UPCASE(15,LN, 'A15‘) EQ '&UVAR' END However, looking at the trace, we see that the WHERE is not optimized because it uses a FOCUS subroutine: SQL SELECT T1."LN",T1."FN",T1.CDEPT,T1."CDIV",T1.PAY FROM master.dbo.EMPSQL T1 ; Of course, if the field in question is being aggregated, or is the GROUP BY for the aggregation, then SQL will do case-insensitive aggregation, so SUBTOTALS with PRINT may be different from a SUM… Sorting also is an issue. Is C less than c, or greater? What to do? Well, since most of our customers live in one world or the other, in release 7.7, you have to specify the environment for a specific server in the server edasprof.prf profile. SET COLLATION = BINARY/ SRV_CI/SRV_CS/CODEPAGE

Where COLLATION is defined as a set of rules that apply to the ordering and matching of all language elements that involve comparison of two values. That means lots of words. When does any language order or match elements? MATCHING: WHERE field EQ value/field , IF field EQ field Used in WHERE/IF tests, DEFINES, COMPUTES, BY(GROUP-BY), ACROSS, EQUI-JOINs ORDERING: Sort(ORDER-BY), IF field LE/GT/GE/LE

• BINARY: bases collation sequence on binary values. • SRV_CI: bases collation sequence on the LANGUAGE setting, and is INSENSITIVE. • SRV_CS: bases collation sequence on LANGUAGE setting and is SENSITIVE. • CODEPAGE: bases collation on the code page in effect, and is SENSITIVE.

The default is CODEPAGE for upper compatibility reasons, though I suspect that most WebFOCUS servers will use SRV_CI (case-insensitive), but those MVS servers will be left at CODEPAGE, because, not just FOCUS, but IMS, IDMS, VSAM keys and indexes are sensitive. What can you expect? To some degree, collation does still depend on operating system, as EBCDIC and ASCII differ. So, since I need to check this every time, here is the comparison: Comparison

COLLATION EBCDIC

ASCII Notes

A ? a SENSITIVE > < INSENSITIVE = = A ? b SENSITIVE > < Binary Values INSENSITIVE < < 1 ? A SENSITIVE > < COLLATION INSENSITIVE > < irrelevant 1 ? a SENSITIVE > < INSENSITIVE > < TABLE FILE EMPSQL PRINT LN FN PAY BY LN WHERE LN EQ ‘DeFazio' OR ‘Fazio' END DEFAZIO DEFAZIO ANTHONY 10,000 DeFazio Anthony 10,000 deFazio Anthony 10,000 Fazio Fazio Anthony 11,000 FAZIO Anthony 9,000 Fazio Anthony 10,000

Notice that all of the variations of the same name are collated together. The BY column contains the FIRST value encountered in the retrieval. Similarly, if you were to SUM alpha field, the value would be either the first or last value based on SUMPREFIX. Most of us live in one world or the other. If all HOLD files, for instance (HOLD FORMAT SAME_DB, FORMAT FOCUS, FORMAT ALPHA, and FORMAT BINARY) are created within the same session where they are used, they should be created in the same COLLATION sequence, so as far as SET COLLATION, “set it and forget it.” Just a few things to look at: A flat file has an unknown sequence, or a known sequence different from what your server expects. A JOIN to a sequential file requires that both files be in ascending order on the JOIN key. If they are of different sort orders, that leads to errors in the JOIN (FOC1071 and/or FOC1072). If a FOCUS file (or XFOC) file has a key or INDEX in an unknown or different COLLATION order, searches through keys may not find all the records desired, and a MODIFY is almost guaranteed to find NOMATCHes. Again, what to do? Recreate that file (or the data you need from that file) in the COLLATION sequence you need. For “flat” files, TABLE FILE filename PRINT * and HOLD. For FOCUS/XFOC files, use REBUILD. Also, in CASE INSENSITIVE, you may see some additional I/O in a TABLE request with a record selection on the “key” field of a SUFFIX=FIX file. FIXRETRIEVE, which stops I/O when a BINARY value of the key in sequential file is greater than the value of the search, would give incorrect results with CASE INSENSITIVE (that whole two-worlds thing again), so FIXRETRIEVE is automatically set OFF for tests on alpha keys when the server is INSENSITIVE. So, where do we go from here? We need you to tell us. What are your concerns? What do you need to know when doing development that you can’t discover? Let us know because any truly useful feature is the one for which multiple people, living in multiple worlds, help define the features.

The 7.7 WebFOCUS Installation Experience By Mona Baker It may not be as exhilarating as the Jimi Hendrix Experience, but you might find a little excitement in the new WebFOCUS installation process. Information Builders made a number of changes to the installation process for WebFOCUS 7.7, and it’s important to know why the changes were necessary. In addition, there are some issues (which are well documented in our release notes) that you should know about so you know what to expect during installation. The main reason we needed to re-write our installation program was because the software package we were using in the 7.6x release (multi-platform installation for Windows and Unix) is no longer supported by the company that provided the multi-platform software. We also always provided an install script for z/OS, AS/400 and iSeries platforms. There are no changes to the platforms that have used the script install. Meanwhile, all Unix platforms will now be using the same script install. In WebFOCUS 7.7 we have two distinct programs for our installation process: 1. On Windows, we use Install Shield to install WebFOCUS. 2. On all other platforms, we use the script install. In WebFOCUS 7.7, there are several changes: 1. The WebFOCUS and ReportCaster Web applications have been combined into one Web application. In prior releases, the two applications were deployed separately with unique context roots whose default values were ibi_apps and rcaster. There is now only one context root for WebFOCUS and ReportCaster with a default value of ibi_apps. Please note that there is a new redirect.war file that can be used by customers who have applications that have hard-coded references to the rcaster alias. This .war file is not needed by all customers and should be deployed only if necessary. 2. FOCUS is no longer supported as a ReportCaster repository, so we distribute and install Derby 10.4.2 as a viable alternative. 3. For your convenience, we distribute Tomcat 6 with WebFOCUS and provide the option to install it as your application server. 4. For Windows platforms, we distribute Java 1.6 and give you an option to install it with WebFOCUS. 5. We offer a silent install option by providing a silent parameter file on all platforms.

The silent install option is easy to use and enables users to run unattended installs, thus increasing productivity. We highly recommend taking advantage of this feature. You should check the parameter file before you run through the install process. On Windows, the silent parameter file is located under the Disk1 directory and is called wf77_install_parms_win.txt. On all other platforms, the parameter file wf77_install_parms_unx.txt is located within the wfclient.tar file and must be extracted. The files come with clear and easy-to-use instructions to help make the silent installation an efficient, time-saving experience. We are exploring new install options for future releases. As with any new product, the installation process for 7.7 and 7.7.01 has had a few anomalies, but these are well documented in the Version 7 Release 7 Release Notes and Upgrade Considerations available from our Technical Documentation web site. Be sure to consult these documents before installing WebFOCUS because they contain the most up-to-date information.