Skip to content

Instantly share code, notes, and snippets.

@masaeedu
Created June 30, 2015 21:34
Show Gist options
  • Save masaeedu/1e6cf72700834543549a to your computer and use it in GitHub Desktop.
Save masaeedu/1e6cf72700834543549a to your computer and use it in GitHub Desktop.
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private async void button1_Click(object sender, EventArgs e)
{
await Task.Run(() =>
{
for (int i = 0; i < 1000000; i++)
{
textBox1.Text = i.ToString();
}
});
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment