コード例 #1
0
 private async void button2_Click(object sender, EventArgs e)
 {
     await TextReaderSample.ReadLinesAsync("oop.md", new Progress <string>(
                                               line => textBox1.Text += line + Environment.NewLine
                                               ));
 }
コード例 #2
0
        private async void button1_Click(object sender, EventArgs e)
        {
            var text = await TextReaderSample.ReadTextAsync("oop.md");

            textBox1.Text = text;
        }