C SHARP – FORM – SAYI ÇEVİRİM İŞLEMLERİ
2’lik sayıları 10’luk sayılara, 10’luk sayıları ise 2’lik sayılara çevirebileceğimiz ufak bir araç.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
| using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows.Forms; namespace _2lik10luk { public partial class Form1 : Form { public Form1() { InitializeComponent(); } private void button2to10_Click( object sender, EventArgs e) { labelsonuc2to10.Text = Convert.ToInt32(textBox1.Text, 2).ToString(); } private void button10to2_Click( object sender, EventArgs e) { labelsonuc10to2.Text = Convert.ToInt32(textBox1.Text, 10).ToString(); } } } |
Hiç yorum yok:
Yorum Gönder