Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
This example displays the current time in a Label.
Example
private void displayTime()
{
Label1.Text = DateTime.Now.ToShortTimeString();
}
Compiling the Code
The form must contain a Labelnamed Label1.
See Also
Concepts
Designing a User Interface in Visual C#