Other
This commit is contained in:
@@ -16,6 +16,8 @@ Imports System.Net
|
||||
Imports System.IO
|
||||
Imports System.Text
|
||||
Imports Newtonsoft.Json
|
||||
Imports SISBusiness.Module.StaticClass
|
||||
Imports DevExpress.ExpressApp.Xpo
|
||||
|
||||
Partial Public Class SISBusinessWindowsFormsApplication
|
||||
Inherits WinApplication
|
||||
@@ -62,6 +64,10 @@ Partial Public Class SISBusinessWindowsFormsApplication
|
||||
GLOBAL_WINFormCaption = String.Format("SISBusiness Framework version: {0} [{1}]", Application.ProductVersion, anm.Version.ToString)
|
||||
GLOBAL_WINFormCaption += String.Format(", ({0})", GLOBAL_Company_Info)
|
||||
GLOBAL_ApplicationStartupPath = Application.StartupPath & "\"
|
||||
|
||||
Dim _ocur As IObjectSpace = CreateObjectSpace()
|
||||
RestAPI.Init(TryCast(_ocur, XPObjectSpace))
|
||||
|
||||
End Sub
|
||||
Protected Overrides Function OnLogonFailed(ByVal logonParameters As Object, ByVal e As Exception) As Boolean
|
||||
If WinChangeDatabaseHelper.SkipLogonDialog Then
|
||||
@@ -115,10 +121,36 @@ Partial Public Class SISBusinessWindowsFormsApplication
|
||||
_InfoString = Encoding.UTF8.GetString(Convert.FromBase64String(_InfoString))
|
||||
_InfoString = AESDecrypt(_InfoString, "HrX12!!0Zm7764W2", "vXm657YS+!0@mmT")
|
||||
|
||||
_GetInfoClass = JsonConvert.DeserializeObject(Of GetInfoClass)(_InfoString)
|
||||
|
||||
Dim sarray() = _InfoString.Split(";")
|
||||
For Each item As String In sarray
|
||||
|
||||
Dim sarray2() = item.Split("=")
|
||||
If sarray2.Length = 2 Then
|
||||
If UCase(LTrim(RTrim(sarray2(0)))) = "DATABASE" Then
|
||||
|
||||
_GetInfoClass.SQLDatabase = sarray2(1)
|
||||
End If
|
||||
If UCase(LTrim(RTrim(sarray2(0)))) = "SERVER" Then
|
||||
|
||||
_GetInfoClass.SQLServer = sarray2(1)
|
||||
End If
|
||||
If UCase(LTrim(RTrim(sarray2(0)))) = "XPOPROVIDER" Then
|
||||
|
||||
If UCase(sarray2(1)) = "MYSQL" Then
|
||||
_GetInfoClass.SQLType = eSQLType.MySQL
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
|
||||
End If
|
||||
|
||||
Next
|
||||
|
||||
|
||||
GLOBAL_Company_Info = String.Format("Server: {0}, Database: {1}", _GetInfoClass.SQLServer, _GetInfoClass.SQLDatabase)
|
||||
GLOBAL_SQLDatabase = _GetInfoClass.SQLDatabase
|
||||
GLOBAL_SQLType = _GetInfoClass.SQLType
|
||||
Catch ex As Exception
|
||||
End Try
|
||||
|
||||
Reference in New Issue
Block a user