addArg

Description

Use to include name and value pairs as parameters that you redirect to another Web page. This method is for use with JSP 4GL targets only.

Applies to

PSArgClass

Syntax

ArgObj.addArg ( String argName, String Value )
ArgObj.addArg ( String argName, boolean Value )
ArgObj.addArg ( String argName, byte Value )
ArgObj.addArg ( String argName, char Value )
ArgObj.addArg ( String argName, double Value )
ArgObj.addArg ( String argName, int Value )
ArgObj.addArg ( String argName, float Value )
ArgObj.addArg ( String argName, long Value )
ArgObj.addArg ( String argName, short Value )
ArgObj.addArg ( String argName, Object Value )

Argument

Description

ArgObj

Object of the PSArgClass type to which you add name-value pairs

argName

Name of the argument you want to add

Value

Value of the argument you want to add

Returns

None

Usage

You can use this overloaded method to add parameters of the supported datatype to the PSArgClass object that you include in a psPage.Redirect call.

Examples

Example 1

This example uses a PSArgClass object with a single parameter. That parameter (param1) is defined on the Parameters tab of the Page Properties dialog box. The value defined for the parameter is added to the PSArgClass object that is included in the psPage.Redirect call:

PSArgClass myParam=null;
myParam = new PSArgClass();
myParam.addArg("param1", param1);
psPage.Redirect("page_2.jsp", myParam);

See also

Redirect