Re: bestimmtes Worddoc. aus Excel öffnen und 3. Tabbl.
21.05.2003 06:39:58
Willie
Hallo Sören ich habe das schon realisiert so kannst du es machen!Sub MeldungInDateiSpeichern()
Sheets("Tabelle3").Select
'-------- Liste in Datei speichern ------------'
Application.ScreenUpdating = False
sDatabaseName = ThisWorkbook.Path & "\Quelle.xls"
ActiveSheet.Copy
antwort = MsgBox("Die Liste wird unter " & sDatabaseName & "!" & " gespeichert!", vbQuestion + vbYesNo, "Soll die Liste gespeichert werden?")
If antwort = vbNo Then
Application.DisplayAlerts = False
ActiveWorkbook.Close
Application.DisplayAlerts = True
Application.ScreenUpdating = True
Exit Sub
Else
Kill sDatabaseName 'Alte oder vorhandene Datei wird ohne Rückfrage gelöscht
ActiveSheet.Buttons.Delete
ActiveWorkbook.SaveAs sDatabaseName
ActiveWorkbook.Close savechanges:=False
Call DokuMeldungen
End If
End Sub
Sub DokuMeldungen()
Set wshshell = CreateObject("WScript.Shell")
Pfad = ThisWorkbook.Path
wshshell.Run Pfad & "\Serienbrief.DOC"
End Sub
Gruß
Willie