- Úgy tér vissza a Commodore 64, ahogy titkon mindenki várja
- A hírek szerint a jövő év végére érkezhet a sokat pletykált NVIDIA N1X SoC
- Egy gyártási hiba miatt nem bootolhatnak bizonyos Minisforum PC-k
- Véget vetne a hibrid magdizájnnak az Intel?
- Elképesztően drága az új Ryzen Threadripper PRO generáció
- AMD Ryzen 9 / 7 / 5 / 3 5***(X) "Zen 3" (AM4)
- Úgy tér vissza a Commodore 64, ahogy titkon mindenki várja
- ROG Strix G16 notebook: tökéletes harmónia
- Véget vetne a hibrid magdizájnnak az Intel?
- TCL LCD és LED TV-k
- Melyik tápegységet vegyem?
- Mégsem búcsúznak a DDR4-es memóriák
- Milyen videókártyát?
- AMD K6-III, és minden ami RETRO - Oldschool tuning
- Milyen billentyűzetet vegyek?
-
PROHARDVER!
Új hozzászólás Aktív témák
-
klambi
addikt
na jó
public partial class Form1 : Form
{
bool osszead = false;
bool kivonas = false;
bool szorzas = false;
bool osztas = false;
public Form1()
{
InitializeComponent();
}private void Form1_Load(object sender, EventArgs e)
{}
private void button9_Click(object sender, EventArgs e)
{
textBox1.Text = textBox1.Text + '1';
}private void button10_Click(object sender, EventArgs e)
{
textBox1.Text = textBox1.Text + '2';
}private void button11_Click(object sender, EventArgs e)
{
textBox1.Text = textBox1.Text + '3';
}private void button14_Click(object sender, EventArgs e)
{
textBox1.Text = textBox1.Text + '4';
}private void button13_Click(object sender, EventArgs e)
{
textBox1.Text = textBox1.Text + '5';
}private void button12_Click(object sender, EventArgs e)
{
textBox1.Text = textBox1.Text + '6';
}private void button17_Click(object sender, EventArgs e)
{
textBox1.Text = textBox1.Text + '7';
}private void button16_Click(object sender, EventArgs e)
{
textBox1.Text = textBox1.Text + '8';
}private void button15_Click(object sender, EventArgs e)
{
textBox1.Text = textBox1.Text + '9';
}private void button18_Click(object sender, EventArgs e)
{
textBox1.Text = textBox1.Text + '0';
}private void button8_Click(object sender, EventArgs e)
{
if (textBox1.Text.Contains('.'))
{
return;
}
else
{
textBox1.Text = textBox1.Text + '.';
}
}private void button19_Click(object sender, EventArgs e)
{
if (textBox1.Text.Contains('-'))
{
textBox1.Text = textBox1.Text.Remove(0, 1);
}
else
{
textBox1.Text = "-" + textBox1.Text;
}
}private void button1_Click(object sender, EventArgs e)
{
if (textBox1.Text == "")
{
return;
}
else
{
osszead = true;
textBox1.Tag = textBox1.Text;
textBox1.Text = "";
}
}private void button5_Click(object sender, EventArgs e)
{
if (osszead)
{
decimal dec = Convert.ToDecimal(textBox1.Tag) + Convert.ToDecimal(textBox1.Text);
textBox1.Text = dec.ToString();}
if (szorzas)
{
decimal dec = Convert.ToDecimal(textBox1.Tag) * Convert.ToDecimal(textBox1.Text);
textBox1.Text = dec.ToString();}
if (osztas)
{
decimal dec = Convert.ToDecimal(textBox1.Tag) / Convert.ToDecimal(textBox1.Text);
textBox1.Text = dec.ToString();}
if (kivonas)
{
decimal dec = Convert.ToDecimal(textBox1.Tag) - Convert.ToDecimal(textBox1.Text);
textBox1.Text = dec.ToString();}
}private void button2_Click(object sender, EventArgs e)
{
if (textBox1.Text == "")
{
return;
}
else
{
kivonas = true;
textBox1.Tag = textBox1.Text;
textBox1.Text = "";
}
}private void button3_Click(object sender, EventArgs e)
{
if (textBox1.Text == "")
{
return;
}
else
{
szorzas = true;
textBox1.Tag = textBox1.Text;
textBox1.Text = "";
}
}private void button4_Click(object sender, EventArgs e)
{
if (textBox1.Text == "")
{
return;
}
else
{
osztas = true;
textBox1.Tag = textBox1.Text;
textBox1.Text = "";
}
}private void button6_Click(object sender, EventArgs e)
{
osztas = osszead = kivonas = szorzas = false;
textBox1.Text = "";
textBox1.Tag = "";
}
}
}simán mennek a dolgok, de a 0 val való osztással szintaktikailag volt gondom...ki is vettem belőle, pontosan hogy lenne az?
Új hozzászólás Aktív témák
● olvasd el a téma összefoglalót!
- AMD Ryzen 9 / 7 / 5 / 3 5***(X) "Zen 3" (AM4)
- Úgy tér vissza a Commodore 64, ahogy titkon mindenki várja
- MIUI / HyperOS topik
- exHWSW - Értünk mindenhez IS
- Intel Dual Core 2000 felhasználók barátságos offolós topikja
- ROG Strix G16 notebook: tökéletes harmónia
- Milyen okostelefont vegyek?
- Sütés, főzés és konyhai praktikák
- Windows 10
- Interactive Brokers társalgó
- További aktív témák...
- Telefon felvásárlás!! iPhone X/iPhone Xs/iPhone XR/iPhone Xs Max
- AKCIÓ! Apple Mac mini 2020 M1 8GB 256GB SSD számítógép garanciával, hibátlan működéssel
- iKing.Hu - Samsung S25 Ultra - Titanium Gray - Használt, karcmentes
- Konzol felvásárlás!! Xbox Series S, Xbox Serries X
- LG 34WR55QK-B - 34" Ívelt VA - 3440x1440 - 100Hz 5ms - FreeSync Premium - HDR 10 - USB Type-C 65W
Állásajánlatok
Cég: PCMENTOR SZERVIZ KFT.
Város: Budapest