Toplam 3 sonuçtan 1 ile 3 arasındakiler gösteriliyor.

Konu: Visual basic Hesap makinessi programı klasik ödev

  1. #1
    ASTSUBAY
    Üyelik tarihi
    Nov 2005
    Mesajlar
    768
    Forum Katkısı:
    0

    Standart Visual basic Hesap makinessi programı klasik ödev

    arkadaşlar kullananlar bilir sık rastlanan bir ÖDEV dir


    Dim a As Variant, b As Variant, islem As Integer, nt As Integer

    Private Sub Command1_Click()
    If Text1.Text = "0" Then
    Text1.Text = ""
    End If
    If nt = 1 Then
    Text1.Text = ""
    nt = 0
    End If
    Text1.Text = Text1.Text + "1"

    End Sub

    Private Sub Command10_Click()
    If Text1.Text <> "0" Then
    Text1.Text = Text1.Text + "0"
    End If
    If nt = 1 Then
    Text1.Text = "0"
    nt = 0
    End If

    End Sub

    Private Sub Command11_Click()
    Text1.Text = "0"
    a = 0
    b = 0
    End Sub

    Private Sub Command12_Click()
    a = Val(Text1.Text)
    islem = 4
    nt = 1
    End Sub

    Private Sub Command13_Click()
    a = Val(Text1.Text)
    islem = 3
    nt = 1
    End Sub

    Private Sub Command14_Click()
    a = Val(Text1.Text)
    islem = 1
    nt = 1
    End Sub

    Private Sub Command15_Click()
    a = Val(Text1.Text)
    islem = 2
    nt = 1
    End Sub

    Private Sub Command16_Click()
    a = Val(Text1.Text)
    Text1.Text = -a
    End Sub

    Private Sub Command17_Click()
    b = Val(Text1.Text)
    Select Case islem
    Case 1
    If b = 0 Then
    Text1.Text = "0'a bölme yapamazsınız."
    Else: Text1.Text = a / b
    End If
    Case 2
    Text1.Text = a * b
    Case 3
    Text1.Text = a - b
    Case 4
    Text1.Text = a + b
    Case 5
    Text1.Text = (a / 100) * b

    End Select
    End Sub

    Private Sub Command18_Click()
    a = Val(Text1.Text)
    Text1.Text = Sqr(a)
    End Sub

    Private Sub Command19_Click()
    b = Val(Text1.Text)
    If islem = 2 Then
    Text1.Text = (a / 100) * b
    End If
    nt = 1
    End Sub

    Private Sub Command2_Click()
    If Text1.Text = "0" Then
    Text1.Text = ""
    End If
    If nt = 1 Then
    Text1.Text = ""
    nt = 0
    End If
    Text1.Text = Text1.Text + "2"

    End Sub

    Private Sub Command20_Click()
    a = Val(Text1.Text)
    Text1.Text = 1 / a
    End Sub

    Private Sub Command21_Click()
    End
    End Sub

    Private Sub Command3_Click()
    If Text1.Text = "0" Then
    Text1.Text = ""
    End If
    If nt = 1 Then
    Text1.Text = ""
    nt = 0
    End If
    Text1.Text = Text1.Text + "3"
    End Sub

    Private Sub Command4_Click()
    If Text1.Text = "0" Then
    Text1.Text = ""
    End If
    If nt = 1 Then
    Text1.Text = ""
    nt = 0
    End If
    Text1.Text = Text1.Text + "4"
    End Sub

    Private Sub Command5_Click()
    If Text1.Text = "0" Then
    Text1.Text = ""
    End If
    If nt = 1 Then
    Text1.Text = ""
    nt = 0
    End If
    Text1.Text = Text1.Text + "5"
    End Sub

    Private Sub Command6_Click()
    If Text1.Text = "0" Then
    Text1.Text = ""
    End If
    If nt = 1 Then
    Text1.Text = ""
    nt = 0
    End If
    Text1.Text = Text1.Text + "6"
    End Sub

    Private Sub Command7_Click()
    If Text1.Text = "0" Then
    Text1.Text = ""
    End If
    If nt = 1 Then
    Text1.Text = ""
    nt = 0
    End If
    Text1.Text = Text1.Text + "7"
    End Sub

    Private Sub Command8_Click()
    If Text1.Text = "0" Then
    Text1.Text = ""
    End If
    If nt = 1 Then
    Text1.Text = ""
    nt = 0
    End If
    Text1.Text = Text1.Text + "9"
    End Sub

    ŞEKİL ÇİZME
    ------------------------------------------

    Option Explicit
    Dim mx, my

    Private Sub Command1_Click()
    End
    End Sub

    Private Sub Form_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
    mx = X
    my = Y
    PSet (X, Y) ' başlangıç noktalarını belirlemek için
    End Sub

    Private Sub Form_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
    If Button = vbRightButton Then Circle (mx, my), Abs(mx - X)
    If Button = vbLeftButton Then Line (mx, my)-(X, Y), , B
    End Sub

    -----------------------------------------------------------------------
    TERS-DÜZ
    -----------------------------------------------------------------------
    Private Sub Form_Load()
    Dim ln As Integer, yarisi As Integer, sayac As Integer
    Dim yari As Single
    Dim uz1 As String, uz2 As String
    sayac = 0
    End Sub

    Private Sub txtText1_KeyPress(KeyAscii As Integer)
    If KeyAscii = 13 Then
    ln = Len(txtText1.Text)
    yari = ln / 2
    'lblYari.Caption = yari
    yarisi = CInt(yari)
    'lblYarisi = yarisi
    For i = 0 To yarisi - 1
    uz1 = Mid$(txtText1.Text, i + 1, 1)
    uz2 = Mid$(txtText1.Text, ln - i, 1)
    If uz1 = uz2 Then
    sayac = sayac + 1
    End If
    Next i
    If sayac = yarisi Then
    lblMesaj.Caption = "tersi duzune esit "
    Else
    lblMesaj.Caption = "tersi duzune esit degil"

    End If
    End If
    End Sub

  2. #2
    ER
    Üyelik tarihi
    May 2005
    Mesajlar
    85
    Forum Katkısı:
    0

    Standart Visual basic Hesap makinessi programı klasik ödev

    Aga hi&#231; bir detayı atlamıyorsun &#246;dev &#246;rneği de vermişsin yaşa ba!

  3. #3
    ER
    Üyelik tarihi
    Nov 2008
    Mesajlar
    54
    Forum Katkısı:
    0

    Standart Cevap: Visual basic Hesap makinessi programı klasik ödev

    eyvallah kardeşim eline sağlık

Konu Bilgisi

Users Browsing this Thread

Şu anda 1 üyemiz bu konuya göz atıyor. (0 kayıtlı üye ve 1 misafir.)

Bu Konuyu Paylaşın !

Bu Konuyu Paylaşın !

Yetkileriniz

  • Konu Acma Yetkiniz Yok
  • Cevap Yazma Yetkiniz Yok
  • Eklenti Yükleme Yetkiniz Yok
  • Mesajınızı Değiştirme Yetkiniz Yok
  •  
Garantili SEO - Moradam