HTML for inserting the controls on a Web page – PB Docs 80

HTML for inserting the controls on a Web page

You include the controls on a Web page with an Object element
and associated Param elements. Then you write scripts that direct
the control to make database connections, retrieve and update data,
and respond to user actions.

The way the Object and Param elements look in a Web page are
described next. When you insert the controls and set their properties
using Web Target development in PowerBuilder, these elements are
coded for you.

Object element

How it works

ActiveX controls use the Object element to specify the GUID
(a unique identifier) of the control as well as the space the control
takes on the page. The Object tag looks like this:

In a Web target, when you insert the Web ActiveX control by
dragging from the System Tree or by using the Insert>Component
menu item, the Object tag is written for you.

CODEBASE attribute

If your users need to download the controls, you can include
the CODEBASE attribute in the Object element to identify the file
to be downloaded. After the browser downloads the CAB file, it unpacks
it and registers the ActiveX controls in the user’s system
registry.

The value for CODEBASE has the format:

A typical value for CODEBASE uses a relative URL:

URL The URL is the location of the DataWindow control’s
CAB file on your Web server. It can be an absolute or relative URL.

Version The version is a set of four numbers, separated by commas.
The numbers must match the version of the CAB file. The version
number of the CAB file is the same as the version number for PowerBuilder
or DataWindow Builder.

proc.gif To find out the 4-part version number in Windows:

  1. Select the PowerBuilder executable, DataWindow
    Builder executable, or a PowerBuilder DLL in Windows Explorer.

  2. Select File>Properties from the menu
    bar.

  3. On the Version tab, look at File Version. A typical
    number is 8.0.1.6012.

Example

The Object element with a CODEBASE attribute looks like this:

New versions

When you get new versions of the CAB file, you can change
the version numbers on the Web page and cause the browser to install
a new version of the control.

For more information about how to deploy new versions, see “Deploying the Web ActiveX”.

Properties and Param elements

How they work

The Web ActiveX and the Transaction Object control have several
properties that specify connection information. The Web ActiveX
also has properties that specify a DataWindow object or a PSR. You
provide values for the properties with Param elements, which are
enclosed in the Object element.

When you insert the controls in a Web target, Param elements
are automatically added to the Web page. You can provide values
for the Param elements using the control property sheets. You can
also write scripts that set or change property values.

The inserted Param elements are grouped in an order that corresponds
to pages in the control property sheets. The first group of Param
elements contains standard ActiveX properties.

The Web ActiveX also inserts Param elements for custom properties
that you set on the General, Scrolling, Transaction, and Trans User
pages of the Sybase DataWindow Web Control Properties dialog box.
The Transaction Object control has only two property pages: Transaction
and Trans User.

Standard ActiveX properties

Properties on General page

Properties on Scrolling page

Properties on Transaction page

Properties on Trans User page


Document get from Powerbuilder help
Thank you for watching.
Was this article helpful?
Subscribe
Notify of
guest
0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x