Merge branch 'master' of http://dd-vmp07-com04:3000/AppStd/ProcessManager_Client
This commit is contained in:
commit
a1b2b1cff4
@ -288,9 +288,6 @@ Public Class ClassControlCreator
|
|||||||
|
|
||||||
Return control
|
Return control
|
||||||
End Function
|
End Function
|
||||||
Private Shared Function ByteArrayToBitmap(bytearray() As Byte) As Bitmap
|
|
||||||
Return New Bitmap(New System.IO.MemoryStream(bytearray))
|
|
||||||
End Function
|
|
||||||
Public Shared Function CreateExistingButton(row As DataRow, designMode As Boolean) As Button
|
Public Shared Function CreateExistingButton(row As DataRow, designMode As Boolean) As Button
|
||||||
Dim oControl As Button = CreateBaseControl(New Button(), row, designMode)
|
Dim oControl As Button = CreateBaseControl(New Button(), row, designMode)
|
||||||
|
|
||||||
@ -420,6 +417,7 @@ Public Class ClassControlCreator
|
|||||||
If Not designMode Then
|
If Not designMode Then
|
||||||
oView.OptionsBehavior.Editable = Not row.Item("READ_ONLY")
|
oView.OptionsBehavior.Editable = Not row.Item("READ_ONLY")
|
||||||
oView.OptionsBehavior.ReadOnly = row.Item("READ_ONLY")
|
oView.OptionsBehavior.ReadOnly = row.Item("READ_ONLY")
|
||||||
|
ocontrol.UseEmbeddedNavigator = Not row.Item("READ_ONLY")
|
||||||
|
|
||||||
If row.Item("VKT_ADD_ITEM") = True Then
|
If row.Item("VKT_ADD_ITEM") = True Then
|
||||||
oView.OptionsBehavior.AllowAddRows = DefaultBoolean.True
|
oView.OptionsBehavior.AllowAddRows = DefaultBoolean.True
|
||||||
|
|||||||
@ -14,16 +14,14 @@ Public Class ClassEncryption
|
|||||||
Dim sha1 As New SHA1CryptoServiceProvider
|
Dim sha1 As New SHA1CryptoServiceProvider
|
||||||
|
|
||||||
' Hash the key.
|
' Hash the key.
|
||||||
Dim keyBytes() As Byte =
|
Dim keyBytes() As Byte = Text.Encoding.Unicode.GetBytes(key)
|
||||||
System.Text.Encoding.Unicode.GetBytes(key)
|
|
||||||
Dim hash() As Byte = sha1.ComputeHash(keyBytes)
|
Dim hash() As Byte = sha1.ComputeHash(keyBytes)
|
||||||
|
|
||||||
' Truncate or pad the hash.
|
' Truncate or pad the hash.
|
||||||
ReDim Preserve hash(length - 1)
|
ReDim Preserve hash(length - 1)
|
||||||
Return hash
|
Return hash
|
||||||
End Function
|
End Function
|
||||||
Public Function EncryptData(
|
Public Function EncryptData(ByVal plaintext As String) As String
|
||||||
ByVal plaintext As String) As String
|
|
||||||
|
|
||||||
' Convert the plaintext string to a byte array.
|
' Convert the plaintext string to a byte array.
|
||||||
Dim plaintextBytes() As Byte =
|
Dim plaintextBytes() As Byte =
|
||||||
@ -40,12 +38,19 @@ Public Class ClassEncryption
|
|||||||
encStream.Write(plaintextBytes, 0, plaintextBytes.Length)
|
encStream.Write(plaintextBytes, 0, plaintextBytes.Length)
|
||||||
encStream.FlushFinalBlock()
|
encStream.FlushFinalBlock()
|
||||||
|
|
||||||
|
Dim oPrintableString = Convert.ToBase64String(ms.ToArray)
|
||||||
|
|
||||||
|
Try
|
||||||
|
ms.Dispose()
|
||||||
|
Catch ex As Exception
|
||||||
|
LOGGER.Error(ex)
|
||||||
|
End Try
|
||||||
|
|
||||||
' Convert the encrypted stream to a printable string.
|
' Convert the encrypted stream to a printable string.
|
||||||
Return Convert.ToBase64String(ms.ToArray)
|
Return oPrintableString
|
||||||
End Function
|
End Function
|
||||||
'Entschlüsselt die Zeichenfolge
|
'Entschlüsselt die Zeichenfolge
|
||||||
Public Function DecryptData(
|
Public Function DecryptData(ByVal encryptedtext As String) As String
|
||||||
ByVal encryptedtext As String) As String
|
|
||||||
|
|
||||||
' Convert the encrypted text string to a byte array.
|
' Convert the encrypted text string to a byte array.
|
||||||
Dim encryptedBytes() As Byte = Convert.FromBase64String(encryptedtext)
|
Dim encryptedBytes() As Byte = Convert.FromBase64String(encryptedtext)
|
||||||
@ -60,9 +65,17 @@ Public Class ClassEncryption
|
|||||||
' Use the crypto stream to write the byte array to the stream.
|
' Use the crypto stream to write the byte array to the stream.
|
||||||
decStream.Write(encryptedBytes, 0, encryptedBytes.Length)
|
decStream.Write(encryptedBytes, 0, encryptedBytes.Length)
|
||||||
decStream.FlushFinalBlock()
|
decStream.FlushFinalBlock()
|
||||||
|
|
||||||
|
' Convert the plaintext stream to a string.
|
||||||
Dim result = System.Text.Encoding.Unicode.GetString(ms.ToArray)
|
Dim result = System.Text.Encoding.Unicode.GetString(ms.ToArray)
|
||||||
result = result.Replace("!Didalog35452Heuchelheim=", "")
|
result = result.Replace("!Didalog35452Heuchelheim=", "")
|
||||||
' Convert the plaintext stream to a string.
|
|
||||||
|
Try
|
||||||
|
ms.Dispose()
|
||||||
|
Catch ex As Exception
|
||||||
|
LOGGER.Error(ex)
|
||||||
|
End Try
|
||||||
|
|
||||||
Return result
|
Return result
|
||||||
End Function
|
End Function
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
@ -1,6 +1,17 @@
|
|||||||
Module ModuleHelper
|
Module ModuleHelper
|
||||||
Public Function ByteArrayToBitmap(bytearray() As Byte) As Bitmap
|
Public Function ByteArrayToBitmap(bytearray() As Byte) As Bitmap
|
||||||
Return New Bitmap(New System.IO.MemoryStream(bytearray))
|
Try
|
||||||
|
Dim oBitmap As Bitmap
|
||||||
|
|
||||||
|
Using oStream As New IO.MemoryStream(bytearray)
|
||||||
|
oBitmap = New Bitmap(oStream)
|
||||||
|
End Using
|
||||||
|
|
||||||
|
Return oBitmap
|
||||||
|
Catch ex As Exception
|
||||||
|
LOGGER.Error(ex)
|
||||||
|
Return Nothing
|
||||||
|
End Try
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
Public Function StringToByteArray(ByVal hex As String) As Byte()
|
Public Function StringToByteArray(ByVal hex As String) As Byte()
|
||||||
|
|||||||
@ -92,8 +92,8 @@ Public Class frmAdministration
|
|||||||
If MyIndicies IsNot Nothing Then
|
If MyIndicies IsNot Nothing Then
|
||||||
Dim i As Integer = 0
|
Dim i As Integer = 0
|
||||||
For Each index As String In MyIndicies
|
For Each index As String In MyIndicies
|
||||||
Dim _vektorString As Boolean = False
|
Dim _vektorString = False
|
||||||
Dim oIndexType = WINDREAM.GetTypeOfIndex(i)
|
Dim oIndexType = WINDREAM.GetTypeOfIndex(index)
|
||||||
i += 1
|
i += 1
|
||||||
MyIndicies_Types.Add(oIndexType)
|
MyIndicies_Types.Add(oIndexType)
|
||||||
Select Case oIndexType
|
Select Case oIndexType
|
||||||
|
|||||||
@ -207,9 +207,6 @@ Public Class frmFormDesigner
|
|||||||
End If
|
End If
|
||||||
Return oType <> FINALINDICES.INDEX_TYPE_VECTOR_DATETIME
|
Return oType <> FINALINDICES.INDEX_TYPE_VECTOR_DATETIME
|
||||||
End Function
|
End Function
|
||||||
Public Function ByteArrayToBitmap(bytearray() As Byte) As Bitmap
|
|
||||||
Return New Bitmap(New System.IO.MemoryStream(bytearray))
|
|
||||||
End Function
|
|
||||||
Sub LoadControls()
|
Sub LoadControls()
|
||||||
Try
|
Try
|
||||||
TBPM_PROFILE_CONTROLSTableAdapter.FillByProfil(DD_DMSLiteDataSet.TBPM_PROFILE_CONTROLS, USER_LANGUAGE, ProfileId)
|
TBPM_PROFILE_CONTROLSTableAdapter.FillByProfil(DD_DMSLiteDataSet.TBPM_PROFILE_CONTROLS, USER_LANGUAGE, ProfileId)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user