Email Formatproblem
Ringlstetter
ich habe ein kleines Problem mit meinem Macro. Ziel ist einfach: Ein Druckbereich aus einem Sheet aus dem WB als neues Sheet in temporärer Datei speichern und per Standard-Emailprogramm an festgesetzte Adresse schicken.
Problemstellung: Ich selbst benutze 2010, der Rest der Firma darf nur 97 [ :D ] Das muß also zwingend mit Excel 97 lesbar sein, also als xls Format mit fileformat xlExcel8.
Es klappt eigentlich auch alles super..der Empfänger (Excel 97) bekommt allerdings nur Hyroglyphen..wer kann helfen?
Hier der Code:
Sub Mail_Range()
Dim source As Range
Dim dest As Workbook
Dim wb As Workbook
Dim TempFilePath As String
Dim TempFileName As String
Dim FileExtStr As String
Dim FileFormatNum As Long
Dim I As Long
Set source = Nothing
On Error Resume Next
Set source = Range(ActiveSheet.PageSetup.PrintArea).SpecialCells(xlCellTypeVisible)
On Error GoTo 0
If source Is Nothing Then
MsgBox "Die Quelle ist leer oder geschützt, bitte korrigieren oder Herrn Ringlstetter _
fragen!", vbOKOnly
Exit Sub
End If
With Application
.ScreenUpdating = False
.EnableEvents = False
End With
Set wb = ActiveWorkbook
Set dest = Workbooks.Add(xlWBATWorksheet)
source.Copy
With dest.Sheets(1)
.Cells(1).PasteSpecial Paste:=8
.Cells(1).PasteSpecial xlPasteValues
.Cells(1).PasteSpecial xlPasteFormats
.Cells(1).Select
Application.CutCopyMode = False
End With
TempFilePath = Environ$("temp") & "\"
TempFileName = "WochenstatistikAktuell"
If Val(Application.Version)