Android Guides | Samples

Android.Widget.Chronometer Class

Class that implements a simple timer.

See Also: Chronometer

Syntax

[Android.Runtime.Register("android/widget/Chronometer", DoNotGenerateAcw=true)]
public class Chronometer : TextView

Remarks

Class that implements a simple timer.

You can give it a start time in the SystemClock.ElapsedRealtime timebase, and it counts up from that, or if you don't give it a base time, it will use the time at which you call Chronometer.Start. By default it will display the current timer value in the form "MM:SS" or "H:MM:SS", or you can use Chronometer.Format to format the timer value into an arbitrary string.

[Android Documentation]

Requirements

Namespace: Android.Widget
Assembly: Mono.Android (in Mono.Android.dll)
Assembly Versions: 0.0.0.0
Since: Added in API level 1

The members of Android.Widget.Chronometer are listed below.

See Also: TextView

Public Constructors

Initialize this Chronometer object.
Initialize with standard view layout information.
Initialize with standard view layout information and style.

Protected Constructors

A constructor used when creating managed representations of JNI objects; called by the runtime.

Public Properties

BaseInt64. Return the base time as set through Chronometer.Base.
FormatString. Returns the current format string as set through Chronometer.Format.
OnChronometerTickListenerChronometer+IOnChronometerTickListener.

Protected Properties

[read-only]
override
ThresholdClassIntPtr. This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.
[read-only]
override
ThresholdTypeType. This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.

Public Methods

Start()
Start counting up.
Stop()
Stop counting up.

Public Events