Anhänge öffnen
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
Imports System.Windows.Forms
|
||||
Imports System.Diagnostics
|
||||
Imports System.Windows.Forms
|
||||
|
||||
Public Class frmAvisoAnfuegen
|
||||
|
||||
@@ -232,4 +233,21 @@ Public Class frmAvisoAnfuegen
|
||||
btnSaveAttachments.Enabled = False
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub dgvAnhaenge_CellContentDoubleClick(sender As Object, e As DataGridViewCellEventArgs) Handles dgvAnhaenge.CellContentDoubleClick, dgvAnhaenge.CellDoubleClick
|
||||
|
||||
Try
|
||||
If dgvAnhaenge.SelectedRows.Count > 0 Then
|
||||
If dgvAnhaenge.SelectedRows(0).Cells(0).Value <> "" Then
|
||||
|
||||
Dim strTmpPath As String = System.IO.Path.GetTempPath()
|
||||
Process.Start(strTmpPath & dgvAnhaenge.SelectedRows(0).Cells(0).Value)
|
||||
|
||||
End If
|
||||
End If
|
||||
Catch ex As Exception
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||
End Try
|
||||
|
||||
End Sub
|
||||
End Class
|
||||
@@ -1,5 +1,6 @@
|
||||
Imports System.Collections
|
||||
Imports System.Data
|
||||
Imports System.Diagnostics
|
||||
Imports System.Diagnostics.Tracing
|
||||
Imports System.Drawing
|
||||
Imports System.Net
|
||||
@@ -406,8 +407,6 @@ Public Class frmAvisoFormularAnfuegen
|
||||
Me.Size = New Size(frmDefaultSize.Width, frmDefaultSize.Height - addHeightfrm)
|
||||
dgvAnhaenge.Size = dgvAnhaengeSize
|
||||
End Select
|
||||
|
||||
|
||||
End If
|
||||
|
||||
dgvAnhaenge.ClearSelection()
|
||||
@@ -469,4 +468,18 @@ Public Class frmAvisoFormularAnfuegen
|
||||
Next
|
||||
End Sub
|
||||
|
||||
Private Sub dgvAnhaenge_CellContentDoubleClick(sender As Object, e As DataGridViewCellEventArgs) Handles dgvAnhaenge.CellDoubleClick, dgvAnhaenge.CellContentDoubleClick
|
||||
Try
|
||||
If dgvAnhaenge.SelectedRows.Count > 0 Then
|
||||
If dgvAnhaenge.SelectedRows(0).Cells(0).Value <> "" Then
|
||||
|
||||
Dim strTmpPath As String = System.IO.Path.GetTempPath()
|
||||
Process.Start(strTmpPath & dgvAnhaenge.SelectedRows(0).Cells(0).Value)
|
||||
|
||||
End If
|
||||
End If
|
||||
Catch ex As Exception
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||
End Try
|
||||
End Sub
|
||||
End Class
|
||||
@@ -167,7 +167,9 @@ Public Class AVISO_Mail_Functions
|
||||
|
||||
If isMail_Barsan(mailItem) Then
|
||||
If vbYes = MsgBox("Barsan-Anhänge laden?", vbYesNoCancel) Then
|
||||
|
||||
getATT_Barsan(mailItem, ATTACHMENTS_LIST)
|
||||
|
||||
End If
|
||||
End If
|
||||
|
||||
@@ -648,6 +650,7 @@ Public Class AVISO_Mail_Functions
|
||||
|
||||
|
||||
Shared Function getATT_Barsan(mailItem As Outlook.MailItem, Optional ByRef ATT As List(Of String) = Nothing, Optional ByRef LKW_Nr As String = "", Optional ByRef RefNr As String = "", Optional ByRef INFO As String = "") As List(Of String)
|
||||
|
||||
If ATT Is Nothing Then ATT = New List(Of String)
|
||||
Try
|
||||
|
||||
@@ -664,7 +667,7 @@ Public Class AVISO_Mail_Functions
|
||||
' Dim sp = html.ToString.Split(srch.ToString)
|
||||
Dim cnt = 0
|
||||
For Each l In sp
|
||||
If cnt > 0 AndAlso l.Contains(""">") AndAlso cnt < 5 Then ' ENDE
|
||||
If cnt > 0 AndAlso l.Contains(""">") Then ' ENDE
|
||||
Dim link = ("https://portal.barsan.com/Dokuman/DokumanGoster.aspx" & l.ToString.Substring(0, l.ToString.IndexOf(""">")))
|
||||
|
||||
|
||||
@@ -676,6 +679,7 @@ Public Class AVISO_Mail_Functions
|
||||
|
||||
If IO.File.Exists(pdf) Then
|
||||
ATT.Add(pdf)
|
||||
Return ATT
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
Reference in New Issue
Block a user