Teach Yourself e.net - Syspro
Teach Yourself e.net - Syspro
Teach Yourself e.net - Syspro
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
Example 5.6. ASP.NET C# codebehind for Utilities.GetLogonProfile<br />
string UserId;<br />
Encore.Utilities Obj = new Encore.Utilities();<br />
try<br />
{<br />
UserId = Obj.Logon("ADMIN", "", "1", "", \<br />
Encore.Language.ENGLISH, 0, 0, " ");<br />
}<br />
catch (Exception exc)<br />
{<br />
Response.Write(("Exception - message:" + exc.Message));<br />
return;<br />
}<br />
string LogonProfile;<br />
try<br />
{<br />
LogonProfile = Obj.GetLogonProfile(UserId);<br />
}<br />
catch (Exception exc)<br />
{<br />
Response.Write(("Exception - message:" + exc.Message));<br />
return;<br />
}<br />
// Display as an XML string<br />
Response.Write(LogonProfile);<br />
Response.ContentType = "text/xml";<br />
long ReturnCode;<br />
ReturnCode = Obj.Logoff(UserId);<br />
Obj = null;<br />
Remember that where ever you see \ at the end of a line of code and the next<br />
line indented, this means that the text was too long for the page size of this<br />
book but the indented text belongs of the code line above.<br />
5.1.4. Utilities.Run<br />
Syntax:<br />
Utilities.Run(UserID, BusinessObject, Parameter)<br />
5–8