Merge branch 'newMaster2024' of https://dev.azure.com/VeragAG/_git/SDL into newMaster2024
This commit is contained in:
@@ -26,6 +26,7 @@ Public Enum cAPI_ART
|
||||
|
||||
AVISO_IN_MSE = 80
|
||||
SDL_OUT_FA = 81
|
||||
SDL_OUT_SAMMELRECHNUNG = 82
|
||||
|
||||
|
||||
End Enum
|
||||
|
||||
@@ -1064,7 +1064,7 @@ Public Class cUTA
|
||||
|
||||
Case "20"
|
||||
|
||||
lngÜbertragungsposition = 6616
|
||||
'lngÜbertragungsposition = 6616
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
Imports System.Net
|
||||
Imports System.Data.SqlClient
|
||||
Imports System.Net
|
||||
Imports System.Text
|
||||
Imports System.Windows.Forms
|
||||
|
||||
@@ -31,6 +32,41 @@ Public Class cTimasAPI
|
||||
End Sub
|
||||
|
||||
|
||||
Public Function loadDgvBySql(ByVal sql As String, Optional conn_art As String = "SDL", Optional timeout As Integer = 0, Optional showerror As Boolean = True) As DataTable
|
||||
Try
|
||||
Dim myTable = New DataTable()
|
||||
Dim conn As New SqlConnection
|
||||
Select Case conn_art
|
||||
|
||||
Case "ADMIN"
|
||||
conn.ConnectionString = "Data Source=SQLGUIDE01.verag.ost.dmn;Initial Catalog=ADMIN;Integrated Security=false;User ID=AppUser;Password=yp/THDd?xM+pZ$"
|
||||
conn.Open()
|
||||
|
||||
|
||||
|
||||
Case "AVISO_ATILLA"
|
||||
conn.ConnectionString = "Data Source=172.16.0.98;Initial Catalog=AVISO_ATILLA;Integrated Security=false;User ID=sa;Password=BmWr501956;Pooling=true;Min Pool Size=5;Max Pool Size=200"
|
||||
conn.Open()
|
||||
End Select
|
||||
' MsgBox(cAllgemein.TESTSYSTEM)
|
||||
' Using conn As SqlConnection = cSqlDb.GetNewOpenConnection()
|
||||
Using cmd As New SqlCommand(sql, conn)
|
||||
If timeout > 0 Then cmd.CommandTimeout = timeout 'Seconds
|
||||
Dim dr As SqlDataReader = cmd.ExecuteReader()
|
||||
|
||||
myTable.Load(dr)
|
||||
dr.Close()
|
||||
End Using
|
||||
conn.Close()
|
||||
' End Using
|
||||
Return myTable 'While Schleife wird hier verlassen
|
||||
Catch ex As Exception
|
||||
If showerror Then VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name, , "WiedergestellungsDatum Fehler", , , sql)
|
||||
End Try
|
||||
|
||||
Return Nothing
|
||||
|
||||
End Function
|
||||
Public Function checkConnectionTImas(ByRef failureText As String) As Boolean
|
||||
Try
|
||||
Dim success As Boolean
|
||||
|
||||
Reference in New Issue
Block a user