kayıt ta debug hatası

Katılım
20 Haziran 2008
Mesajlar
697
Excel Vers. ve Dili
Microsoft Office ev ve iş 2019
Altın Üyelik Bitiş Tarihi
03-07-2024
selam
aşağıdaki kod ile textbox5 ile textbox6 yı çarpıp sonucu textbox7 ye aldırıyorum kayıt butonunda debug hatası veriyor sorun nereden kaynaklanıyor

Private Sub TextBox5_Change()
'**************ÇARPMA**kod başlangıç*******************
If Len(TextBox5.Text) = 0 Then Exit Sub
If Not IsNumeric(TextBox5.Text) Then
Beep
MsgBox "Harf girilmeyecek,Sadece Rakam Giriniz .......!!", vbOKOnly, "dikkat !!!"
End If
End Sub
Private Sub TextBox6_Change()
On Error Resume Next
TextBox7 = FormatNumber(TextBox5 * TextBox6)
If Err <> 0 Then TextBox7 = Empty
'textbox formatı*******************
TextBox7 = Format(TextBox7, "##,##0.00 TL") '
End Sub
'********ÇARPMA**kod BİTİŞ*********
 
Katılım
6 Mayıs 2008
Mesajlar
125
Excel Vers. ve Dili
Microsoft Excel 2007 Tr
selam
aşağıdaki kod ile textbox5 ile textbox6 yı çarpıp sonucu textbox7 ye aldırıyorum kayıt butonunda debug hatası veriyor sorun nereden kaynaklanıyor

Private Sub TextBox5_Change()
'**************ÇARPMA**kod başlangıç*******************
If Len(TextBox5.Text) = 0 Then Exit Sub
If Not IsNumeric(TextBox5.Text) Then
Beep
MsgBox "Harf girilmeyecek,Sadece Rakam Giriniz .......!!", vbOKOnly, "dikkat !!!"
End If
End Sub
Private Sub TextBox6_Change()
On Error Resume Next
TextBox7 = FormatNumber(TextBox5 * TextBox6)
If Err <> 0 Then TextBox7 = Empty
'textbox formatı*******************
TextBox7 = Format(TextBox7, "##,##0.00 TL") '
End Sub
'********ÇARPMA**kod BİTİŞ*********
Merhaba kodu alıp bir sayfada denedim çarpım işlemini doğru bir şekilde yapıyor sorun yok.Heralde çıkan sonucu kayıt ederken hata veriyor sizin.Kayıt butonundaki kodları da yazarsanız size yardımcı olurlar.
 
Katılım
20 Haziran 2008
Mesajlar
697
Excel Vers. ve Dili
Microsoft Office ev ve iş 2019
Altın Üyelik Bitiş Tarihi
03-07-2024
kayıt butonu kodları ektedır
Private Sub CommandButton1_Click()
Dim h As Integer
If TextBox2.Value = "" Then
MsgBox "Lütfen STOKTAKİ ÜRÜN LİSTESİNDEN ürün seçiniz.", vbCritical, "U Y A R I"
Exit Sub
End If
If TextBox3.Value = "" Then
MsgBox "Ürün İsmi Giriniz", vbCritical, "MUSTAFA KÖKER"
Exit Sub
End If
If TextBox4.Value = "" Then
MsgBox "Ürün Alt İsmi Giriniz", vbCritical, "MUSTAFA KÖKER"
Exit Sub
End If
If TextBox5.Value = "" Then
MsgBox "Miktar Giriniz", vbCritical, "MUSTAFA KÖKER"
Exit Sub
End If
If TextBox6.Value = "" Then
MsgBox "Fiyat Giriniz", vbCritical, "MUSTAFA KÖKER"
Exit Sub
End If
If TextBox7.Value = "" Then
MsgBox "Tutar Giriniz", vbCritical, "MUSTAFA KÖKER"
Exit Sub
End If
If ComboBox1.Value = "" Then
MsgBox "Birim Seçiniz", vbCritical, "MUSTAFA KÖKER"
Exit Sub
End If
With Sheets("FATURA")
For h = 17 To 38
If .Range("A" & h) = "" Then Exit For
Next h
If h > 38 Then
MsgBox "Fatura dolu.Yazdırıp Yeni fatura Takınız...", vbCritical, "U Y A R I"
GoTo bosalt
End If
.Cells(h, 1) = TextBox2.Text
.Cells(h, 2) = TextBox3.Text
.Cells(h, 3) = TextBox4.Text
.Cells(h, 4) = TextBox5.Text * 1
.Cells(h, 5) = ComboBox1.Text
.Cells(h, 6) = TextBox6.Text * 1
.Cells(h, 7) = TextBox7.Text * 1
bosalt:
TextBox2.Text = ""
TextBox3.Text = ""
TextBox4.Text = ""
TextBox5.Text = ""
TextBox6.Text = ""
TextBox7.Text = ""

ComboBox1.Text = ""
TextBox2.SetFocus
End With
End Sub
 
Katılım
20 Haziran 2008
Mesajlar
697
Excel Vers. ve Dili
Microsoft Office ev ve iş 2019
Altın Üyelik Bitiş Tarihi
03-07-2024
selam
aşağıdaki kod ile textbox5 ile textbox6 yı çarpıp sonucu textbox7 ye aldırıyorum kayıt butonunda debug hatası veriyor sorun nereden kaynaklanıyor

Private Sub TextBox5_Change()
'**************ÇARPMA**kod başlangıç*******************
If Len(TextBox5.Text) = 0 Then Exit Sub
If Not IsNumeric(TextBox5.Text) Then
Beep
MsgBox "Harf girilmeyecek,Sadece Rakam Giriniz .......!!", vbOKOnly, "dikkat !!!"
End If
End Sub


Private Sub TextBox6_Change()
On Error Resume Next
TextBox7 = FormatNumber(TextBox5 * TextBox6)
If Err <> 0 Then TextBox7 = Empty
'textbox formatı*******************
TextBox7 = Format(TextBox7, "##,##0.00 TL") '
End Sub
'********ÇARPMA**kod BİTİŞ*********
konu guncelleme
 
Katılım
31 Ocak 2010
Mesajlar
547
Excel Vers. ve Dili
Excel 2003
Merhaba.
Private Sub TextBox6_Change() 'deki

"TextBox7 = Format(TextBox7, "##,##0.00 TL") "

formatından dolayı

Buton altındaki

".Cells(h, 7) = TextBox7.Text * 1" bölümü

".Cells(h, 7) = TextBox7.Text " şeklinde olmalı.
 
Katılım
20 Haziran 2008
Mesajlar
697
Excel Vers. ve Dili
Microsoft Office ev ve iş 2019
Altın Üyelik Bitiş Tarihi
03-07-2024
Merhaba.
Private Sub TextBox6_Change() 'deki

"TextBox7 = Format(TextBox7, "##,##0.00 TL") "

formatından dolayı

Buton altındaki

".Cells(h, 7) = TextBox7.Text * 1" bölümü

".Cells(h, 7) = TextBox7.Text " şeklinde olmalı.
işe yaramadı

*1 metini sayıya dönüştürüp excel sayfasında sayısal değer olarak göstermeye yarıyor yanlış bilmiyorsam eğer
 
Katılım
20 Haziran 2008
Mesajlar
697
Excel Vers. ve Dili
Microsoft Office ev ve iş 2019
Altın Üyelik Bitiş Tarihi
03-07-2024
sorun benım evdekı pc den kaynaklanıyormuş çok özür dilerim iş teki pc de denediğimde sorun yok fakat benım excelım mı bozuldu runtime error 13 -type mismach hatası verıyor
ne yapabılırım
 
Üst