Use Database from Monorepo, Add initial ODBC Support
This commit is contained in:
@@ -135,7 +135,7 @@ Public Class frmAdministration
|
||||
For Each row As DataRow In MyDataset.TBWH_User.Rows
|
||||
If row.Item(0) = CBool(True) Then
|
||||
Dim insert = String.Format("INSERT INTO TBCW_USER_PROFILE (PROFILE_ID,USER_ID) VALUES ({0},{1})", GUIDTextBox.Text, row.Item(5))
|
||||
If clsDatabase.Execute_non_Query(insert) = False Then
|
||||
If Database.ExecuteNonQuery(insert) = False Then
|
||||
MsgBox("Could not insert the User-Definition....Check the logfile!", MsgBoxStyle.Exclamation)
|
||||
End If
|
||||
End If
|
||||
@@ -157,7 +157,7 @@ Public Class frmAdministration
|
||||
Dim Sql = String.Format("SELECT DISTINCT * FROM VWDD_USER_MODULE_CW WHERE GUID NOT IN (SELECT USER_ID FROM TBCW_USER_PROFILE WHERE PROFILE_ID = {0}) ORDER BY USERNAME", PROFILE_ID)
|
||||
|
||||
|
||||
Dim DT_USER = clsDatabase.Return_Datatable(Sql)
|
||||
Dim DT_USER = Database.GetDatatable(Sql)
|
||||
Try
|
||||
MyDataset.TBWH_User.Clear()
|
||||
|
||||
@@ -185,7 +185,7 @@ Public Class frmAdministration
|
||||
|
||||
Sub Refresh_Free_Groups(PROFILE_ID As Integer)
|
||||
Dim Sql = String.Format("SELECT DISTINCT * FROM TBDD_GROUPS WHERE GUID NOT IN (SELECT GROUP_ID FROM TBCW_GROUP_PROFILE WHERE PROFILE_ID = {0}) ORDER BY NAME", PROFILE_ID)
|
||||
Dim oDataTable = clsDatabase.Return_Datatable(Sql)
|
||||
Dim oDataTable = Database.GetDatatable(Sql)
|
||||
|
||||
Try
|
||||
MyDataset.TBWH_GROUP.Clear()
|
||||
@@ -211,7 +211,7 @@ Public Class frmAdministration
|
||||
Exit Sub
|
||||
End Try
|
||||
Dim del = String.Format("DELETE FROM TBCW_USER_PROFILE WHERE GUID = {0}", ID)
|
||||
If clsDatabase.Execute_non_Query(del) = True Then
|
||||
If Database.ExecuteNonQuery(del) = True Then
|
||||
Refresh_ProfileData()
|
||||
If GUIDTextBox.Text <> "" Then
|
||||
Refresh_Free_Users(GUIDTextBox.Text)
|
||||
@@ -294,7 +294,7 @@ Public Class frmAdministration
|
||||
Dim result As MsgBoxResult = MsgBox("Sind Sie sicher, dass Sie das Profil löschen wollen?", MsgBoxStyle.YesNo, "Bestätigung erforderlich:")
|
||||
' wenn Speichern ja
|
||||
If result = MsgBoxResult.Yes Then
|
||||
If clsDatabase.Execute_non_Query(swl) = True Then
|
||||
If Database.ExecuteNonQuery(swl) = True Then
|
||||
Load_Profiles()
|
||||
End If
|
||||
End If
|
||||
@@ -364,7 +364,7 @@ Public Class frmAdministration
|
||||
Dim oRow As DataRow = GridViewUserNotInProfile.GetDataRow(oRowHandle)
|
||||
Dim oGuid As Integer = oRow.Item("ID")
|
||||
Dim insert = String.Format("INSERT INTO TBCW_USER_PROFILE (PROFILE_ID,USER_ID) VALUES ({0},{1})", GUIDTextBox.Text, oGuid)
|
||||
If clsDatabase.Execute_non_Query(insert) = False Then
|
||||
If Database.ExecuteNonQuery(insert) = False Then
|
||||
MsgBox("Error while adding user!", MsgBoxStyle.Exclamation)
|
||||
End If
|
||||
Next
|
||||
@@ -393,7 +393,7 @@ Public Class frmAdministration
|
||||
Dim oRow As DataRow = GridViewUserInProfile.GetDataRow(oRowHandle)
|
||||
Dim oGuid As Integer = oRow.Item("GUID")
|
||||
Dim del = String.Format("DELETE FROM TBCW_USER_PROFILE WHERE GUID = {0}", oGuid)
|
||||
If clsDatabase.Execute_non_Query(del) = False Then
|
||||
If Database.ExecuteNonQuery(del) = False Then
|
||||
MsgBox("Error while adding user!", MsgBoxStyle.Exclamation)
|
||||
End If
|
||||
Next
|
||||
@@ -419,7 +419,7 @@ Public Class frmAdministration
|
||||
Dim oGroupId As Integer = oRow.ID
|
||||
Dim oSQL As String = $"INSERT INTO TBCW_GROUP_PROFILE (PROFILE_ID,GROUP_ID) VALUES ({GUIDTextBox.Text},{oGroupId})"
|
||||
|
||||
If clsDatabase.Execute_non_Query(oSQL) = False Then
|
||||
If Database.ExecuteNonQuery(oSQL) = False Then
|
||||
MsgBox("Could not insert the Group-Definition....Check the logfile!", MsgBoxStyle.Exclamation)
|
||||
End If
|
||||
Next
|
||||
@@ -444,7 +444,7 @@ Public Class frmAdministration
|
||||
Dim oGroupId As Integer = oRow.GUID
|
||||
Dim oSQL As String = $"DELETE FROM TBCW_GROUP_PROFILE WHERE GUID = ({oGroupId})"
|
||||
|
||||
If clsDatabase.Execute_non_Query(oSQL) = False Then
|
||||
If Database.ExecuteNonQuery(oSQL) = False Then
|
||||
MsgBox("Could not delete the Group-Definition....Check the logfile!", MsgBoxStyle.Exclamation)
|
||||
End If
|
||||
Next
|
||||
|
||||
Reference in New Issue
Block a user