Hallo zusammen,
ich möchte, dass mir beim abspeichern eines Worddokuments schon folgendes im Feld Dateiname angezeigt wird:
Datum - SSP -
also z.b.
20210312 - SSP -
das Datum habe ich schon gefunden, den SSP teil mit den Strichen und Leerzeichen kriege ich nicht hin. Und wie muss ich das abspeichern, damit es immer so ist? Als Vorlage?
Public Sub FileSave1()
Dim xDlg As Dialog
Dim xTitle As String
On Error Resume Next
xTitle = ActiveDocument.BuiltInDocumentProperties("Title").Value
xTitle = xTitle & " " & Format((Year(Now() + 1) Mod 100), "20##") & _
Format((Month(Now() + 1) Mod 100), "0#") & _
Format((Day(Now()) Mod 100), "0#")
Set xDlg = Dialogs(wdDialogFileSaveAs)
xDlg.Name = xTitle
xDlg.Show
End Sub
Danke und VG
Julius
|