Improve Logging, Fix Email Indexing
This commit is contained in:
@@ -11,13 +11,13 @@ Public Class ClassFileDrop
|
||||
|
||||
Public Shared Function Drop_File(e As DragEventArgs)
|
||||
Try
|
||||
LOGGER.Info("Available Drop Formats:")
|
||||
LOGGER.Debug("Available Drop Formats:")
|
||||
|
||||
For Each oFormat As String In e.Data.GetFormats()
|
||||
LOGGER.Info(oFormat)
|
||||
LOGGER.Debug(oFormat)
|
||||
Next
|
||||
|
||||
LOGGER.Info(">> Drop_File")
|
||||
LOGGER.Info("Drop_File")
|
||||
files_dropped = Nothing
|
||||
If e.Data.GetDataPresent(DataFormats.FileDrop) Then
|
||||
Dim MyFiles() As String
|
||||
@@ -26,7 +26,7 @@ Public Class ClassFileDrop
|
||||
MyFiles = e.Data.GetData(DataFormats.FileDrop)
|
||||
' Loop through the array and add the files to the list.
|
||||
For i = 0 To MyFiles.Length - 1
|
||||
LOGGER.Info(">> Simple FileDrop - File: " & MyFiles(i))
|
||||
LOGGER.Info("Simple FileDrop - File: " & MyFiles(i))
|
||||
ReDim Preserve files_dropped(i)
|
||||
files_dropped(i) = "|DROPFROMFSYSTEM|" & MyFiles(i)
|
||||
' ListBox1.Items.Add(MyFiles(i))
|
||||
@@ -85,10 +85,10 @@ Public Class ClassFileDrop
|
||||
If (finTemp.Exists = True) Then
|
||||
ReDim Preserve files_dropped(0)
|
||||
files_dropped(0) = "|OUTLOOK_ATTACHMENT|" & strOutFile
|
||||
LOGGER.Info(">> Drop an Attachment - File: " & strOutFile)
|
||||
LOGGER.Info("Drop an Attachment - File: " & strOutFile)
|
||||
Return True
|
||||
Else
|
||||
LOGGER.Info(">> Attachment File from Outlook could not be created")
|
||||
LOGGER.Info("Attachment File from Outlook could not be created")
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
@@ -102,7 +102,7 @@ Public Class ClassFileDrop
|
||||
Return False
|
||||
End Try
|
||||
|
||||
LOGGER.Info(">> Drop of msg")
|
||||
LOGGER.Info(" Drop of msg")
|
||||
'supports a drop of a Outlook message
|
||||
Dim myobj As Outlook.MailItem
|
||||
For i As Integer = 1 To oApp.ActiveExplorer.Selection.Count
|
||||
@@ -125,7 +125,7 @@ Public Class ClassFileDrop
|
||||
oFilename = oFilename.Replace("!", "")
|
||||
oFilename = oFilename.Replace("%", "")
|
||||
oFilename = oFilename.Replace("$", "")
|
||||
LOGGER.Info(">> Drop of msg - File:" & oFilename)
|
||||
LOGGER.Info("Drop of msg - File:" & oFilename)
|
||||
Try
|
||||
myobj.SaveAs(oFilename)
|
||||
Catch ex As Exception
|
||||
@@ -146,8 +146,6 @@ Public Class ClassFileDrop
|
||||
MsgBox("Error in Drop-File" & vbNewLine & ex.Message, MsgBoxStyle.Critical)
|
||||
Return False
|
||||
End Try
|
||||
|
||||
|
||||
End Function
|
||||
|
||||
'Private Sub DragDrop_HandleTobit(e As DragEventArgs)
|
||||
|
||||
Reference in New Issue
Block a user