This commit is contained in:
Developer01 2025-01-06 10:12:13 +01:00
parent eb527fc619
commit 1f32baeb8d
2 changed files with 12 additions and 3 deletions

View File

@ -31,5 +31,5 @@ Imports System.Runtime.InteropServices
' übernehmen, indem Sie "*" eingeben:
' <Assembly: AssemblyVersion("1.0.*")>
<Assembly: AssemblyVersion("2.1.0.0")>
<Assembly: AssemblyVersion("2.1.1.0")>
<Assembly: AssemblyFileVersion("1.0.0.0")>

View File

@ -67,8 +67,17 @@ Public Class frmMain
TBDD_USERTableAdapter.Connection.ConnectionString = MyConnectionString
TBDD_USER_MODULESTableAdapter.Connection.ConnectionString = MyConnectionString
Dim sql = String.Format("SELECT * FROM [dbo].[FNDD_LOGIN_USER_MODULE] ('{0}','UM',1)", Environment.UserName)
Dim DT_CHECKUSER_MODULE As DataTable = MyDatabase.GetDatatable(sql)
Dim oSql = String.Format("SELECT * FROM [dbo].[FNDD_LOGIN_USER_MODULE] ('{0}','UM',1)", Environment.UserName)
Dim DT_CHECKUSER_MODULE As DataTable
Try
DT_CHECKUSER_MODULE = MyDatabase.GetDatatable(oSql)
Catch ex As Exception
MyLogger.Warn($"Error Executing: FNDD_LOGIN_USER_MODULE: {ex.Message}")
MyLogger.Warn($"SQL so far: [{oSql}]")
Application.ExitThread()
End Try
If DT_CHECKUSER_MODULE.Rows.Count = 0 Then
MsgBox($"Der Benutzer '{Environment.UserName}' ist nicht zur Benutzerverwaltung berechtigt. {vbCrLf & vbCrLf}Bitte kontaktieren Sie den Administrator, wenn dies ein Fehler ist.", MsgBoxStyle.Critical, "UserManager")