Unterschrift

Aus Thomas Wiki
Zur Navigation springen Zur Suche springen

Einfügen einer "Unterschrift" mit Datum und Namen in ein Dokument.

Lotus Notes Formula Language

Die folgende Lotus Notes Formel fügt das Datum und den Namen an der Stelle des Cursors in ein zum Editieren geöffnetes Dokument ein. (Formel in einem SmartIcon in einer Symbolleiste definieren.)

tmpDate:=@Now;
sDate:=@Right("00"+@Text(@Day(tmpDate));2) + "."+ @Right("00"+@Text(@Month(tmpDate));2) + "." + @Text(@Year (tmpDate)) ;
@Command([TextSetFontFace]; "Comic Sans MS");
@Command([TextSetFontColor];[Blue]);
@Command([EditInsertText]; @NewLine + sDate + " - Mein Name")

Microsoft Word

Sub Unterschrift()

  MyUserName = "Mein Name"
 
  With Selection
    .TypeParagraph
    OldColor = .Font.Color
    .Font.Color = wdColorBlue
    .InsertDateTime DateTimeFormat:="dd.MM.yy", InsertAsField:= _
    False, DateLanguage:=wdGerman, CalendarType:=wdCalendarWestern, _
    InsertAsFullWidth:=False
    .TypeText Text:=" - " & MyUserName
    .Font.Color = OldColor
  End With
   
End Sub