Progress
Language Reference


LOAD( ) Method

Loads an XML document into memory, parses it, and makes its contents available in the 4GL.

Return Type: LOGICAL

Applies To: X-document Object Handle

SYNTAX
LOAD( mode , { file |  memptr } , validate ) 

mode

“FILE” or “MEMPTR”.

file

A character expression that represents the name of a file. You can specify a relative pathname, an absolute pathname, or an HTTP URL.

memptr

A MEMPTR variable that contains the loaded XML text. The size of the MEMPTR variable should match the size of the XML text.

validate

A logical expression where TRUE indicates that the parser should validate the document’s logical structure with respect to its Document Type Definition (DTD). Note that even if validation against the DTD is not specified, the document’s physical structure is still validated.

The following code fragment creates a parse tree of XML nodes and does validation:

DEFINE VARIABLE hDoc AS HANDLE.
CREATE X-DOCUMENT hDoc.
hDoc:LOAD("file","memo.xml",true).
. . . 


Copyright © 2004 Progress Software Corporation
www.progress.com
Voice: (781) 280-4000
Fax: (781) 280-4095