Available for: UI for ASP.NET Core | UI for ASP.NET MVC | UI for ASP.NET AJAX | UI for Blazor | UI for WPF | UI for WinForms | UI for Xamarin | UI for WinUI

New to Telerik Document Processing? Download free 30-day trial

Time Field

TimeField is a Field element that inserts the current time in your document.

Field Syntax

This is how the syntax of a If field looks like:

Syntax
{ TIME [\@ "Date-Time Picture"] }

Switches

Switches are a way for the code fragment to specify formatting for the result of the field. More information is available in the Syntax and Switches section of the Fields article.

The possible switches for a time field are:

Switch Description
\@ "Date-Time Picture" Specifies a date format if different than the default format

Inserting

Inserting a merge field is easily achieved through the RadFlowDocumentEditor's InsertField() method. It accepts code as first argument and result as second argument.

Example 1 demonstrates how you can insert a merge field.

Example 1: Insert merge field

editor.InsertField("TIME \@ \"h:mm:ss am/pm\"", "to be updated"); 

After updating the field the result would be "5:28:34 PM" (check Updating Fields).

See Also

In this article
Not finding the help you need? Improve this article