Connection Information

To perform the requested action, WordPress needs to access your web server. Please enter your FTP credentials to proceed. If you do not remember your credentials, you should contact your web host.

Connection Type

SetData – PB Docs 2022 – PowerBuilder Library

SetData – PB Docs 2022

SetData

Description

Sets the raw data for the PBDOM_PROCESSINGINSTRUCTION
object.

Syntax

Argument

Description

pbdom_pi_name

The name of a PBDOM_PROCESSINGINSTRUCTION
object

strData

New data for the PBDOM_PROCESSINGINSTRUCTION
object

Return value

PBDOM_PROCESSINGINSTRUCTION. The PBDOM_PROCESSINGINSTRUCTION
object modified with the new data.

Throws

EXCEPTION_INVALID_STRING — The input data is invalid. This can
happen in the following circumstances:

  1. The input data contains the sub-string “?>”. This violates
    the requirements for the data of a processing instruction.

  2. If the processing instruction target name is xml, making this
    PBDOM_PROCESSINGINSTRUCTION object an XML declaration processing
    instruction, this exception is thrown if the input data string does
    not conform to the following criteria:

    • The data must contain a name/value pair for the name
      version.

    • The data can contain a name/value pair for the name
      encoding.

    • The data can contain a name/value pair for the name
      standalone. If it does, the value for standalone must either be
      yes or no.

    • The data must not contain any other data in the form of
      name/value pairs or in any other form.

Lowercase

The strings xml, version, encoding, standalone, yes, and no are
all case sensitive and must be in lowercase.

Examples

Suppose there is a PBDOM_PROCESSINGINSTRUCTION object as
follows:

Then, SetData(“href=new.xsl”) results in the
PBDOM_PROCESSINGINSTRUCTION object being transformed into the
following:

The entire data for the PBDOM_PROCESSINGINSTRUCTION object is now
reset.

Usage

Special processing is performed when the name of the processing
instruction’s target is xml, which indicates that it is an XML
declaration. The valid instructions allowed in the input Data as part of
the name in the name/value pairs are version, encoding, and standalone.
The version instruction is mandatory before the processing instruction
can be added to a document.

The XML specification expects the instructions to be in the
specific order version , encoding , standalone. This function reorders
the input data to conform to the specification, for example:


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