Syntax
Function CreateOffice(ParentUsername As String,Name As String,Username As String,Password As String ,ShowAsDemo As Boolean,ReadOnlyLogin As Boolean,Phone As String,Fax As String,Mobile As String,TelPWD As String,POB As String,Email As String,Address As String, ChangePW As Boolean, TransTag As String,Optional ParentUserID as Integer = -1) As CallingResultsEnum
Description
To create a new office for a specific parent in a parent tree. After CreateOffice method executes the CreateOfficeResult event fire.
Parameters
Part |
Description |
ParentUsername |
Parent Username where you want to create an office for , a value of type String. |
Name |
The name of the office, value of type String. |
Username |
The username of the office, value of type String. |
Password |
The password of the office, value of type String. |
ShowAsDemo |
Boolean Parameter, if true the office will appear as demo office. |
ReadOnlyLogin |
Boolean Parameter, if true the office will only monitor the trades. |
Phone |
Office’s Phone Number, a value of type String. |
Fax |
Office’s Fax Number, a value of type String. |
Mobile |
Office’s Mobile Number, a value of type String. |
TelPWD |
Office's Telephone password, a value of type String. |
POB |
Post Office Box,value of type String. |
Email |
Office’s Email, a value of type String. |
Address |
Office’s Address, a value of type String. |
TransTag |
String value to mark create office operation when the result came from the server. |
ChangePW |
Used to detect if the created client will force change password after the first login, value of type Boolean. |
ParentUserID |
If the username is empty you can pass the parent Id that you want to create the Office under, an optional value of type is Integer |
Return value
Returns a value of type CallingResultsEnum. if the requested sent to the server successfully it will return SuccessResult.
Sample
Public WithEvents m_oBOAPI As CVertexFXBOAPI
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim result As VertexFXBOAPI11.CallingResultsEnum
Dim ParentUsername, Name, Username, Password, Fax, Phone, mob As String
Dim TelPWD, POB, Country, Email, Address As String
Dim ReadOnlyLogin ,ShowAsDemo As Boolean
Dim ParentUserId as Integer = -1
Name = "test"
Username = "test1"
Password = "1234"
Fax = "11223"
TelPWD = "123456789"
ParentUsername = "trial1"
POB = "1001"
Country = "Jordan"
Email = "abc@abc.com"
Address = "amman"
TransTag = "xxx"
ReadOnlyLogin = False
ShowAsDemo = True
result = m_oBOAPI.CreateOffice(ParentUsername,Name, Username,Password , ShowAsDemo ,ReadOnlyLogin , Phone, Fax, mob, TelPWD, POB, Email, Address,false ,TransTag,ParentUserId)
MsgBox(result.ToString) ' if it equal SuccessResult that mean it sent to the server successfully.
End Sub
See Also
VertexFX Backoffice API Index
|