pfad
This commit is contained in:
@@ -171,32 +171,36 @@ Public Class cAllgemein
|
|||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Public Shared Sub LOAD_CHAT_EMOJIS()
|
Public Shared Sub LOAD_CHAT_EMOJIS()
|
||||||
|
|
||||||
Dim EMOJI_SOURCEPATH = DATENVERVER_OPTIONS.getRootDir & "\DOKUMENTE\CHAT_EMOJIS\"
|
|
||||||
Dim EMOJI_SOURCELIST = System.IO.Directory.GetFiles(EMOJI_SOURCEPATH).ToList
|
|
||||||
|
|
||||||
EMOJI_PATH = System.IO.Path.GetFullPath(My.Application.Info.DirectoryPath & "\Resources\CHAT_EMOJIS\")
|
|
||||||
|
|
||||||
Try
|
Try
|
||||||
If Not System.IO.Directory.Exists(EMOJI_PATH) Then
|
If System.IO.Directory.Exists(DATENVERVER_OPTIONS.getRootDir & "\DOKUMENTE\CHAT_EMOJIS\") Then
|
||||||
System.IO.Directory.CreateDirectory(EMOJI_PATH)
|
|
||||||
End If
|
Dim EMOJI_SOURCEPATH = DATENVERVER_OPTIONS.getRootDir & "\DOKUMENTE\CHAT_EMOJIS\"
|
||||||
|
Dim EMOJI_SOURCELIST = System.IO.Directory.GetFiles(EMOJI_SOURCEPATH).ToList
|
||||||
|
|
||||||
|
EMOJI_PATH = System.IO.Path.GetFullPath(My.Application.Info.DirectoryPath & "\Resources\CHAT_EMOJIS\")
|
||||||
|
|
||||||
|
|
||||||
For Each f In System.IO.Directory.GetFiles(EMOJI_PATH)
|
If Not System.IO.Directory.Exists(EMOJI_PATH) Then
|
||||||
Dim fi As New System.IO.FileInfo(f)
|
System.IO.Directory.CreateDirectory(EMOJI_PATH)
|
||||||
If Not System.IO.Directory.GetFiles(EMOJI_PATH).Any(Function(c) c.Equals(fi.Name, StringComparison.OrdinalIgnoreCase)) Then
|
|
||||||
System.IO.File.Delete(f)
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Next
|
|
||||||
|
|
||||||
For Each f In System.IO.Directory.GetFiles(EMOJI_SOURCEPATH)
|
For Each f In System.IO.Directory.GetFiles(EMOJI_PATH)
|
||||||
Dim fi As New System.IO.FileInfo(f)
|
Dim fi As New System.IO.FileInfo(f)
|
||||||
fi.CopyTo(EMOJI_PATH & fi.Name, False)
|
If Not System.IO.Directory.GetFiles(EMOJI_PATH).Any(Function(c) c.Equals(fi.Name, StringComparison.OrdinalIgnoreCase)) Then
|
||||||
|
System.IO.File.Delete(f)
|
||||||
|
End If
|
||||||
|
|
||||||
Next
|
Next
|
||||||
|
|
||||||
|
For Each f In System.IO.Directory.GetFiles(EMOJI_SOURCEPATH)
|
||||||
|
Dim fi As New System.IO.FileInfo(f)
|
||||||
|
fi.CopyTo(EMOJI_PATH & fi.Name, False)
|
||||||
|
|
||||||
|
Next
|
||||||
|
Else
|
||||||
|
MsgBox("Fehler: Chat-Emojis Verzeichnis existiert nicht!")
|
||||||
|
End If
|
||||||
|
|
||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||||
|
|||||||
Reference in New Issue
Block a user