Stopwatch

  • November 2019
  • PDF

This document was uploaded by user and they confirmed that they have the permission to share it. If you are author or own the copyright of this book, please report to us by using this DMCA report form. Report DMCA


Overview

Download & View Stopwatch as PDF for free.

More details

  • Words: 104
  • Pages: 1
public partial class form1 : form { stopwatch s = new stopwatch(); public form1() { initializecomponent(); } private void form1_load(object sender, eventargs e) { } private void button1_click(object sender, eventargs e) { if (button1.text == "start") { button1.text = "stop"; button2.text = "caputre"; s.start(); } else if (button1.text == "stop") { button1.text = "start"; button2.text = "reset"; s.stop(); } } private void button2_click(object sender, eventargs e) { if (s.isrunning == true) { button2.text = "cap"; label1.text = label2.text;

}

} else { s.reset(); label2.text = s.elapsed.tostring(); }

private void timer1_tick(object sender, eventargs e) { if (s.isrunning == true) { label2.text = s.elapsed.tostring(); } }

Related Documents

Stopwatch
November 2019 1
Report Project Stopwatch
November 2019 4
Stopwatch 3 Tb.pdf
December 2019 1