Date.Now-Methode
Ruft das aktuelle Systemdatum und die aktuelle Systemuhrzeit im ISO-Format (JJJJ-MM-TThh:mm:ss) ab.
Namespace: Microsoft.Office.Interop.InfoPath
Assembly: Microsoft.Office.Interop.InfoPath (in microsoft.office.interop.infopath.dll)
Syntax
'Declaration
<DispIdAttribute(1)> _
Function Now As Object
'Usage
Dim instance As Date
Dim returnValue As Object
returnValue = instance.Now
[DispIdAttribute(1)]
Object Now ()
Rückgabewert
Ein object-Element zur Darstellung des aktuellen Datums und der aktuellen Uhrzeit.
Beispiel
Im folgenden Beispiel wird die currentDateTime-Variable auf das aktuelle Systemdatum und die aktuelle Systemuhrzeit festgelegt:
object currentDateTime = thisXDocument.Util.Date.Now();
thisXDocument.UI.Alert(currentDateTime.ToString());
Siehe auch
Referenz
Date-Schnittstelle
Date-Member
Microsoft.Office.Interop.InfoPath-Namespace