Parse Method
Parse the IDoc data.
Syntax
idocreader.parse([callback])
Callback
The 'callback' parameter specifies a function which will be called when the operation completes (or an error is encountered). If the 'callback' parameter is not specified, then the method will block and will not return until the operation completes (or an error is encountered).
The callback for this method is defined as:
function(err){ }
'err' is the error that occurred. If there was no error, then 'err' is 'null'.
'err' has 2 properties which hold detailed information:
err.code err.message
Remarks
When called this will attempt to read the file specified by InputFile or the data in InputData. Note that you will need to set the ImportFormat property to the format of the document you are trying to read;
Example IDocReader Code
idocreader1.ImportSchemaFromSAP("BUPA_FS_ADDEXTERNID01") idocreader1.ImportFormat = 0 'ifPlainText idocreader1.InputFile = "C:\idoc_inbound\BUPA_FS_ADDEXTERNID0001.idoc" idocreader1.Parse()