• Giriş

Gorsel Programlama

  • AnaSayfa
  • Hakkımızda
  • TOP-10 Proje
  • Download
  • Özel Ders
  • Reklam Verin
  • Destek
  • İletişim
RSS feed
  • Youdao
  • Xian Guo
  • Zhua Xia
  • Google
  • My Yahoo!
  • newsgator
  • Bloglines
  • iNezha
© 2009-2023 Gorsel Programlama

Windows Bilimsel Hesap Makinesi — Csharp

Windows Bilimsel Hesap Makinesi — Csharp


using System;

using System.Collections.Generic;

using System.ComponentModel;

using System.Data;

using System.Drawing;//www.gorselprogramlama.com

using System.Text;

using System.Windows.Forms;

namespace Modern_Hesap_Makinesi

{

public partial class Modern_Hesap_Makinesi : Form

{

decimal birinciSayi, ikinciSayi, hafiza;

string islem;

Boolean sonuclandi,farkliMi;

public Modern_Hesap_Makinesi()

{

InitializeComponent();

}

private void Modern_Hesap_Makinesi_Load(object sender, System.EventArgs e)

{

txtSonuc.Focus();

this.Text = "Hesap Makinesi";

txtSonuc.Text = "";

}//www.gorselprogramlama.com

decimal sonuc;

private void rakamlar(object sender, System.EventArgs e)

{

if (sonuclandi)

txtSonuc.Text = (sender as Button).Text;

else

{

txtSonuc.Text = txtSonuc.Text + (sender as Button).Text;

}

sonuclandi = false;

}

private void btnArtiEksi_Click(object sender, System.EventArgs e)

{

if (txtSonuc.Text.Length > 0)

if (txtSonuc.Text.Substring(0, 1) == "-")

//Sayinin basinda - varsa sil

txtSonuc.Text = txtSonuc.Text.Substring(1);

else

//- yoksa - ekle

txtSonuc.Text = "-" + txtSonuc.Text.Substring(0);

}//www.gorselprogramlama.com

private void btnVirgul_Click(object sender, System.EventArgs e)

{

//sayida virgul yoksa

if (txtSonuc.Text.IndexOf(",") <= 0)

if (txtSonuc.Text.Length == 0)

//hiç karakter yoksa 0, ekle

txtSonuc.Text = "0,";

else

//sayi varsa sonuna virgul ekle

txtSonuc.Text = txtSonuc.Text + ",";

}

private void btnSil_Click(object sender, System.EventArgs e)

{

txtSonuc.Text = "";

sonuc = 0;//www.gorselprogramlama.com

op = "";

}

private void btnGeriSil_Click(object sender, System.EventArgs e)

{

if (txtSonuc.Text.Length > 0)

{

txtSonuc.Text = txtSonuc.Text.Substring(0, txtSonuc.Text.Length - 1);

}

}

private void hafiza_islemleri(object sender, System.EventArgs e)

{

if (txtSonuc.Text.Length == 0)

{

txtSonuc.Text = "0";

}

switch ((sender as Button).Text)

{

case "MC":

hafiza = 0;

break;

case "M+":

hafiza = hafiza + decimal.Parse(txtSonuc.Text);

break;//www.gorselprogramlama.com

case "M-":

hafiza = hafiza - decimal.Parse(txtSonuc.Text);

break;

case "MR":

txtSonuc.Text = hafiza.ToString();

break;

}

}

private void Button_Esit_Click(object sender, System.EventArgs e)

{

if (txtSonuc.Text.Length == 0)

{

txtSonuc.Text = "0";

}

txtSonuc.Text = sonuc.ToString();

sonuclandi = true;

}

private void islem_Yap_2(object sender, System.EventArgs e)

{

decimal sayi;

if (txtSonuc.Text.Length == 0)

txtSonuc.Text = "0";

sayi = decimal.Parse(txtSonuc.Text);

switch ((sender as Button).Text)

{

case "Kök":

if (sayi >= 0)

txtSonuc.Text = Math.Sqrt((double)sayi).ToString();

break;

case "x²"://www.gorselprogramlama.com

txtSonuc.Text = (sayi * sayi).ToString();

break;

case "1/x":

if (sayi != 0)

txtSonuc.Text = (1 / sayi).ToString();

break;

}

}

string op;

private void btnArtii_Click(object sender, EventArgs e)

{

if (btnArtii.Text == op)

{

sonuc += decimal.Parse(txtSonuc.Text);

txtSonuc.Text = sonuc.ToString();

}

else

{

sonuc = decimal.Parse(txtSonuc.Text);

txtSonuc.Text = sonuc.ToString();

}

sonuclandi = true;

op = "+";

}

private void btnEksii_Click(object sender, EventArgs e)

{

if (btnEksii.Text == op)

{

if (sonuc == 0)

{

sonuc = decimal.Parse(txtSonuc.Text);

txtSonuc.Text = sonuc.ToString();

}

else

{

sonuc -= decimal.Parse(txtSonuc.Text);

txtSonuc.Text = sonuc.ToString();

}

}

else

{

sonuc = decimal.Parse(txtSonuc.Text);

txtSonuc.Text = sonuc.ToString();

}

sonuclandi = true;

op = "-";

}

private void btnboluu_Click(object sender, EventArgs e)

{

if (btnboluu.Text== op)

{

if (sonuc == 0)

{

sonuc = decimal.Parse(txtSonuc.Text);

txtSonuc.Text = sonuc.ToString();

}

else

{

sonuc /= decimal.Parse(txtSonuc.Text);

txtSonuc.Text = sonuc.ToString();

}

}

else

{

sonuc = decimal.Parse(txtSonuc.Text);//www.gorselprogramlama.com

txtSonuc.Text = sonuc.ToString();

}

sonuclandi = true;

op = "/";

}

private void btnCarpii_Click(object sender, EventArgs e)

{

if (btnCarpii.Text == op)

{

if (sonuc == 0)

{

sonuc = decimal.Parse(txtSonuc.Text);

txtSonuc.Text = sonuc.ToString();

}

else

{

sonuc *= decimal.Parse(txtSonuc.Text);

txtSonuc.Text = sonuc.ToString();

}

}

else

{

sonuc = decimal.Parse(txtSonuc.Text);

txtSonuc.Text = sonuc.ToString();

}

sonuclandi = true;

op = "*";

}

private void btnUs_Click(object sender, EventArgs e)

{

if (btnUs.Text == op)//www.gorselprogramlama.com

{

sonuc = decimal.Parse( Math.Pow(double.Parse(sonuc.ToString()),double.Parse(txtSonuc.Text)).ToString());

txtSonuc.Text = sonuc.ToString();

}

else

{

sonuc = decimal.Parse(txtSonuc.Text);

txtSonuc.Text = sonuc.ToString();

}

sonuclandi = true;

op = "x^y";

}

private void btnSin_Click(object sender, EventArgs e)

{

sonuc = decimal.Parse(Math.Sin((Math.PI* double.Parse(txtSonuc.Text))/180.0).ToString());

txtSonuc.Text = sonuc.ToString();

sonuclandi = true;

}

private void btnCos_Click(object sender, EventArgs e)

{

sonuc = decimal.Parse(Math.Cos((Math.PI * double.Parse(txtSonuc.Text)) / 180.0).ToString());

txtSonuc.Text = sonuc.ToString();//www.gorselprogramlama.com

sonuclandi = true;

}

private void btnTan_Click(object sender, EventArgs e)

{

sonuc = decimal.Parse(Math.Tan((Math.PI * double.Parse(txtSonuc.Text)) / 180.0).ToString());

txtSonuc.Text = sonuc.ToString();

sonuclandi = true;

}

private void btnSinh_Click(object sender, EventArgs e)

{

sonuc = decimal.Parse(Math.Sinh(double.Parse(txtSonuc.Text)).ToString());

txtSonuc.Text = sonuc.ToString();

sonuclandi = true;

}

private void btnCosh_Click(object sender, EventArgs e)

{

sonuc = decimal.Parse(Math.Cosh(double.Parse(txtSonuc.Text)).ToString());

txtSonuc.Text = sonuc.ToString();

sonuclandi = true;

}

private void btnTanh_Click(object sender, EventArgs e)

{

sonuc = decimal.Parse(Math.Tanh(double.Parse(txtSonuc.Text)).ToString());

txtSonuc.Text = sonuc.ToString();//www.gorselprogramlama.com

sonuclandi = true;

}

private void btnKup_Click(object sender, EventArgs e)

{

sonuc = decimal.Parse(Math.Pow(double.Parse(txtSonuc.Text), double.Parse("3")).ToString());

txtSonuc.Text = sonuc.ToString();

sonuclandi = true;

}

private void btnFaktoriyel_Click(object sender, EventArgs e)

{

sonuc = 1;

if (decimal.Parse(txtSonuc.Text) == 0)

{

sonuc = 1;

txtSonuc.Text = sonuc.ToString();

}

else

{

for (decimal i =decimal.Parse(txtSonuc.Text) ; i >0; i--)

{

sonuc *= i;

}

txtSonuc.Text = sonuc.ToString();

}

sonuclandi = true;

}

private void btnOnUzeri_Click(object sender, EventArgs e)

{

string s="1";

if (decimal.Parse(txtSonuc.Text) == 0)

{

sonuc = 1;

txtSonuc.Text = sonuc.ToString();

}

else

{

for (decimal i = decimal.Parse(txtSonuc.Text); i > 0; i--)

{

s += "0";

}

sonuc = decimal.Parse(s);

txtSonuc.Text = sonuc.ToString();//www.gorselprogramlama.com

}

sonuclandi = true;

}

private void btnLog_Click(object sender, EventArgs e)

{

sonuc = decimal.Parse(Math.Log10(double.Parse(txtSonuc.Text)).ToString());

txtSonuc.Text = sonuc.ToString();

sonuclandi = true;

}

private void btnMod_Click(object sender, EventArgs e)

{

if (btnMod.Text == op)

{

sonuc = decimal.Parse((double.Parse(sonuc.ToString())% double.Parse(txtSonuc.Text)).ToString());

txtSonuc.Text = sonuc.ToString();

}

else

{

sonuc = decimal.Parse(txtSonuc.Text);

txtSonuc.Text = sonuc.ToString();

}

sonuclandi = true;

op = "Mod";

}

}//www.gorselprogramlama.com

}

Projeyi İNDİR

Paylaş :
Tweet
Yorum Yazın | Geri
9 Mayıs Cuma,2014 Tarihinde Yayınlanmıştır. Bulunduğu Kategori : C#
Etiket: Application, C#, code, Csharp, csharp örnekleri, form uygulamaları, forms, kod, örnek, uygulama, windows, Windows Bilimsel Hesap Makinesi -- Csharp
« Rasgele Üretilen Sayılardan Büyük , Küçük Sayıyı Gösterme Ve Sıralama — Csharp Kenarları Girilen Üçgenin Türü — Csharp »
Henüz Yorum Yok.

Yorum Yazın ...

Cevabı İptal
XHTML: Bu Etiketleri Kullanabilirsiniz : <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>
RSS Bu Yazıya Yapılan Yorumlar


Site içi Arama

Takip et: @GorselProgram







Böyle bir web sayfam olsun diyorsanız iletişim bölümünden veya gorselprogram@gmail.com mail adresinden bize ulaşabilirsiniz.

Son Yazılar

  • 2022-2023 öğretim yılı bilgisayar tasarım uygulamaları dersi 1.dönem 2.sınav (uygulama) sınav soruları ve cevap anahtarı
  • İdeal Kilo Hesaplama C# Csharp
  • Kullanıcı adı ve şifre bilgileri ile gizli bilgiyi gösteren program Csharp C#
  • ComboBox nesnesi içinden seçilen bir harfin sesli harf mi, sessiz harf mi olduğunu bulan program Csharp C#
  • ComboBox nesnesi içinden seçilen bir harfin, alfabenin kaçıncı harfi olduğunu bulan programı switch-case kullanarak Csharp C#

Etiket Bulutu

.NET Application basit C# C#.NET application C#.NET codes C#.NET examples C#.NET lessons C#.NET practice C#.net örnekleri c# console dersleri c# console örnekleri C# ders c# dersleri c# örnek c# örnekleri C.net dersleri c dersleri code console console örnekleri Csharp csharp dersleri csharp net csharp örnekleri c örnekleri download Flash örnekleri forms Forms örnekleri full indir kod kodlar nesne tabanlı programlama OleDbConnection OleDbDataAdapter tam sürüm uygulama vb net win windows windows forms application örnek ücretsiz

Kategoriler

  • Access (59)
  • Akış Diyagramı Flowchart (69)
  • Android Eğitimleri (2)
  • Asp Net (47)
  • C# (834)
  • C# Console (222)
  • Css (19)
  • Dersler (191)
  • Dökümanlar (21)
  • Dreamweaver (12)
  • Excel (8)
  • Fireworks (28)
  • Flash (77)
  • Görsel Programlama (421)
  • GorselProgramlama.Com (8)
  • Html (35)
  • Pascal (2)
  • Photoshop (5)
  • PHP (2)
  • Planlar (114)
  • Programlama Tanım (4)
  • Sınavlar (142)
  • Sql (10)
  • VB 6.0 (45)
  • VB.NET (219)
  • Videolar (65)
  • Word (7)

Arşiv

Bağlantılar

  • Html Dersleri
  • Muslu.NET
  • Programlama Dersleri

Kimler Sitede ?


    Computers Blogs Top programming blogs

   sayaç Powered by WordPress | Theme by NeoEase | Valid XHTML 1.1 and CSS 3 Yukarı