Webmaster Destek Forumu

Yarınların için bir şey yapmazsan, ölene dek Alarm kurmaya mahkumsun !
İletişim
  • Webmaster forumu olarak, web geliştirme ve dijital pazarlama gibi konularda bilgi paylaşımı yapabileceğiniz webmaster sitesi ve freelancer forumu kategorilerimizle size en iyi deneyimi sunuyoruz! katılım ve kullanım tamamen Ücretsizdir!

C# Hesap Makinesi Kodları

Panther

Forum Üyesi
Katılım
18 Eki 2022
Mesajlar
50
Puanları
0
Yaş
34
Konum
istanbul
Kodlar:
Kod: Tümünü Seç Tümünü Kopyala
Kod:
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace HesapMakinesi
{
public partial class Form1 : Form
{
double ilk_sayı = 0;
public Form1()
{
InitializeComponent();
}

private void textBox1_TextChanged(object sender, EventArgs e)
{

}

private void button1_Click(object sender, EventArgs e)
{
if (ilk_sayı != 0) textBox1.Text = "0";
if (textBox1.Text == "0") textBox1.Text = "";
textBox1.Text = textBox1.Text + button1.Text;
}

private void button2_Click(object sender, EventArgs e)
{
if (ilk_sayı != 0) textBox1.Text = "0";

if (textBox1.Text == "0") textBox1.Text = "";
textBox1.Text = textBox1.Text + button2.Text;

}

private void button3_Click(object sender, EventArgs e)
{
if (ilk_sayı != 0) textBox1.Text = "0";

if (textBox1.Text == "0") textBox1.Text = "";
textBox1.Text = textBox1.Text + button3.Text;
}

private void button4_Click(object sender, EventArgs e)
{
if (ilk_sayı != 0) textBox1.Text = "0";

if (textBox1.Text == "0") textBox1.Text = "";
textBox1.Text = textBox1.Text + button4.Text;
}

private void button5_Click(object sender, EventArgs e)
{
if (textBox1.Text == "0") textBox1.Text = "";
textBox1.Text = textBox1.Text + button5.Text;
}

private void button6_Click(object sender, EventArgs e)
{
if (textBox1.Text == "0") textBox1.Text = "";
textBox1.Text = textBox1.Text + button6.Text;
}

string işlem = "";
private void button7_Click(object sender, EventArgs e)
{
ilk_sayı = Convert.ToDouble(textBox1.Text);
textBox1.Text = "0";
işlem = "-";

}

private void button9_Click(object sender, EventArgs e)
{
if (işlem == "-")
textBox1.Text = (ilk_sayı - Convert.ToDouble(textBox1.Text)).ToString();
if (işlem == "*")
textBox1.Text = (ilk_sayı * Convert.ToDouble(textBox1.Text)).ToString();
if (işlem == "+")
textBox1.Text = (ilk_sayı + Convert.ToDouble(textBox1.Text)).ToString();
if (işlem == "/")
textBox1.Text = (ilk_sayı / Convert.ToDouble(textBox1.Text)).ToString();
}

private void button8_Click(object sender, EventArgs e)
{
ilk_sayı = Convert.ToDouble(textBox1.Text);
textBox1.Text = "0";
işlem = "*";
}

private void Form1_Load(object sender, EventArgs e)
{

}
double ikinci = 0;
private void button10_Click(object sender, EventArgs e)
{
if (ilk_sayı == 0)
{
ilk_sayı = Convert.ToDouble(textBox1.Text);
textBox1.Text = "0";
işlem = "+";
}
else
{
ikinci = ilk_sayı + Convert.ToDouble(textBox1.Text);
textBox1.Text = ikinci.ToString();

}
}

private void button11_Click(object sender, EventArgs e)
{
ilk_sayı = Convert.ToDouble(textBox1.Text);
textBox1.Text = "0";
işlem = "/";
}

private void button12_Click(object sender, EventArgs e)
{

textBox1.Text = textBox1.Text + button12.Text;

}

private void button15_Click(object sender, EventArgs e)
{
if (textBox1.Text == "0") textBox1.Text = "";
textBox1.Text = textBox1.Text + button15.Text;
}

private void button14_Click(object sender, EventArgs e)
{
if (textBox1.Text == "0") textBox1.Text = "";
textBox1.Text = textBox1.Text + button14.Text;
}

private void button13_Click(object sender, EventArgs e)
{
if (textBox1.Text == "0") textBox1.Text = "";
textBox1.Text = textBox1.Text + button13.Text;
}

private void button16_Click(object sender, EventArgs e)
{
if (textBox1.Text == "0") textBox1.Text = "";
textBox1.Text = textBox1.Text + button16.Text;
}

private void button17_Click(object sender, EventArgs e)
{
ilk_sayı = 0;
textBox1.Text = "0";
}

private void button18_Click(object sender, EventArgs e)
{
if (textBox1.Text.Length == 1) textBox1.Text = "0";
else
textBox1.Text = textBox1.Text.Substring(0, textBox1.Text.Length - 1);
}
}
}
 

Webmaster Forumları

Webmaster forumu arayanlar için en doğru adreslerden biri olan sitemiz, geniş içerik yelpazesiyle webmaster dünyasına dair her türlü ihtiyacınıza cevap vermektedir. Xenforo destek hizmetlerimizden faydalanabilir, ücretsiz scriptler ve ücretsiz backlink olanaklarından yararlanabilirsiniz. Sitemiz ayrıca, SEO çalışmaları yapmak isteyenler için en kapsamlı SEO forumları arasında yer almaktadır.

Webmaster Forumu

Sitemizde makale satışı, link değişimi, web site tanıtımı gibi işlemleri güvenle gerçekleştirebilirsiniz. Özellikle tanıtım yazısı ile sitenizin görünürlüğünü artırabilir, geniş kitlelere ulaşabilirsiniz. Ayrıca, sosyal medya uzmanlarına yönelik özel bir sosyal medya forumu ile dijital dünyada fark yaratmak isteyen herkesin buluşma noktasıyız.

Katılım sağlamak ve bilgi paylaşımında bulunmak için türkçe webmaster forumları arasında en iyisi olan platformumuzda siz de yerinizi alın!

Üst