20.01.2015 Views

Teach Yourself e.net - Syspro

Teach Yourself e.net - Syspro

Teach Yourself e.net - Syspro

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

The Class Library Reference<br />

End Try<br />

Response.ContentType = "text/xml"<br />

Response.Write(XmlOut)<br />

Response.End()<br />

' Logoff and Cancel your current Session<br />

Dim ReturnCode As Long<br />

ReturnCode = Obj.Logoff(UserId)<br />

Setup = Nothing<br />

Obj = Nothing<br />

5.4. Transaction Class<br />

The Transaction class has two Methods with it's class structure: Post, and Build.<br />

Use the e.<strong>net</strong> Diagnostics suite's Harness tool to see the method options displayed when<br />

you select the Transaction class:<br />

By selecting each different method and clicking on the business object drop down menu<br />

you can see which business objects are available for that particular method within the<br />

Setup class.<br />

5.4.1. Transaction.Post<br />

Syntax:<br />

Utilities.Transaction(UserID, BusinessObject, XmlParameters,<br />

XmlIn)<br />

The Post method enables transactions to be posted to SYSPRO.<br />

The return XML string will indicate success or failure. More complex Post methods will<br />

use the Build method to assist with building the XML data.<br />

The Transaction.Post method requires two XML input strings. The first,<br />

XmlParameters is used to pass parameters to the Business Object. The second, XmlIn<br />

contains the data to be posted to SYSPRO. The Business Object will return an XML string<br />

indicating success or failure.<br />

The structure and parameters allowed in XmlParameters and XmlIn is dependent on<br />

the business object being called.<br />

5–37

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!