Define Visual C#.Net

C# Form Control

C# Label Control

C# TextBox Control

C# Button Control

C# RadioButton Control

C# CheckBox Control

C# CheckListBox

C# ListBox Control

C# ComboBox Control

C# LinkLabel Control

C# DateTime DataType

C# DateTimePicker

C# NumericUpDown

C# RandomNumber

C# PictureBox

C# ProgressBar

C# Timer Control

C# ToolTip

C# TabControl

C# RichTextBox

C# MessageBox

C# Menu Control

C# Toolbars

C# Dialogs Box

Page Stats

Visitor: 165

Timer Control in C#.Net

The Timer control is used to execute commands for every tick of time which is specified with an interval. For example, if you want to print your name for every 5 seconds, then you can use the Timer control.

enabled interval

private void timer1_Tick(object sender, EventArgs e)
        {
            progressBar1.Value = progressBar1.Value + 2;
            if (progressBar1.Value == 100)
            {
                timer1.Enabled = false;
                this.Hide();
                Form2 f2 = new Form2();
                f2.Show();
            }
        }