20.01.2015 Views

Teach Yourself e.net - Syspro

Teach Yourself e.net - Syspro

Teach Yourself e.net - Syspro

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

The Class Library Reference<br />

Example 5.4. ASP.NET Visual Basic codebehind for Utilities.Logoff<br />

'Logoff and Cancel your current Session<br />

Dim ReturnCode As Long<br />

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

Obj = Nothing<br />

5.1.3. Utilities.GetLogonProfile<br />

Syntax:<br />

Utilities.GetLoginProfile(UserID)<br />

The GetLoginProfile method returns an XML string containing additional details<br />

about your current SYSPRO session.<br />

Business objects available to this method include:<br />

• COMLGN<br />

Example 5.5. ASP.NET Visual Basic codebehind for<br />

Utilities.GetLogonProfile<br />

'Fetch Logon profile Information<br />

Dim LoginProfile As String<br />

Try<br />

LoginProfile = Obj.GetLogonProfile(UserID)<br />

Catch exc As Exception<br />

Response.Write("Exception - message:" & exc.Message)<br />

Exit Sub<br />

End Try<br />

'Display as an XML string<br />

Response.Write(LoginProfile)<br />

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

5–7

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

Saved successfully!

Ooh no, something went wrong!