• DİKKAT

    DOSYA İndirmek/Yüklemek için ÜCRETLİ ALTIN ÜYELİK Gereklidir!
    Altın Üyelik Hakkında Bilgi

toplama kodunda hata

Katılım
25 Aralık 2007
Mesajlar
335
Excel Vers. ve Dili
exel 2000 türkçe
aşağıdaki kod ile
[ez1] = WorksheetFunction.Sum(Range("ed2:ed65536"))
ed sütünlarının toplamını ez1 hücersine toplatmak istiyorum
ancak hic bir sey olmuyor nasıl düzeltebilirim.
(aynı kodu sayfaya koyfuğum butonla yaparsam hesaplama yapıyor ancak userformdan olmuyor)

nesne nin diğer kodları aşağıdaki gibidir.

Private Sub Label33_Click()
Set sh = Sheets("CARİ")
If TextBox3.Value = "" Then
MsgBox "ÖNCE MÜŞTERİ SEÇİN", vbExclamation, "HATALI İŞLEM"
Exit Sub
End If
ListBox1.Enabled = False
EndRow = sh.Cells(65536, 105).End(xlUp).Row
sh.Cells(EndRow + 1, 105) = TextBox3
sh.Cells(EndRow + 1, 106) = TextBox4
sh.Cells(EndRow + 1, 107) = TextBox5
sh.Cells(EndRow + 1, 108) = TextBox6
sh.Cells(EndRow + 1, 109) = TextBox7
sh.Cells(EndRow + 1, 110) = TextBox8
sh.Cells(EndRow + 1, 111) = TextBox9
sh.Cells(EndRow + 1, 112) = TextBox10
sh.Cells(EndRow + 1, 113) = TextBox11
sh.Cells(EndRow + 1, 114) = TextBox12
sh.Cells(EndRow + 1, 115) = TextBox13
sh.Cells(EndRow + 1, 116) = TextBox14
sh.Cells(EndRow + 1, 117) = TextBox15
sh.Cells(EndRow + 1, 118) = TextBox16
sh.Cells(EndRow + 1, 119) = ComboBox2
sh.Cells(EndRow + 1, 120) = ComboBox1
sh.Cells(EndRow + 1, 121) = TextBox33
sh.Cells(EndRow + 1, 122) = TextBox34
sh.Cells(EndRow + 1, 123) = TextBox17
sh.Cells(EndRow + 1, 124) = TextBox18
sh.Cells(EndRow + 1, 125) = TextBox19
sh.Cells(EndRow + 1, 126) = TextBox20
sh.Cells(EndRow + 1, 127) = TextBox22
sh.Cells(EndRow + 1, 128) = TextBox23
sh.Cells(EndRow + 1, 129) = TextBox24
sh.Cells(EndRow + 1, 130) = TextBox25
sh.Cells(EndRow + 1, 131) = TextBox29
sh.Cells(EndRow + 1, 132) = TextBox27
sh.Cells(EndRow + 1, 133) = TextBox28
sh.Cells(EndRow + 1, 134) = TextBox26
sh.Cells(EndRow + 1, 135) = TextBox31
sh.Cells(EndRow + 1, 136) = TextBox35
sh.Cells(EndRow + 1, 137) = TextBox36
TextBox22 = ""
TextBox23 = ""
TextBox24 = ""
TextBox25 = ""
TextBox26 = ""
TextBox27 = ""
TextBox28 = ""
TextBox29 = ""
Label33.Caption = "TUTAR"
Label33.BackColor = &H8000000F
CommandButton7_Click
[ez1] = WorksheetFunction.Sum(Range("ed2:ed65536")) TextBox30 = [ez1]
listele_Click
listele1_Click
End Sub
 
:hey:
Burada bir şey eksik değilmi?
Niye atladınız?
Kolay gelsin.:cool:

Kod:
[ez1] = WorksheetFunction.Sum([B][COLOR="Red"][SIZE="3"]sh.[/SIZE][/COLOR][/B]Range("ed2:ed65536"))
 
aşağıdaki kodlamayı yapıp deneyin.
sonucu alıyorsanız alt satırlarda deneyin.
alt satırlarda bir proplem var.
Belkide textboxlar ilgili hücrelere boşluk değeri atıyor.
Not : bu kodlama label33 ün click olayına yazılmış.Başka bir yere tıklamış olmayın:cool:

Kod:
Private Sub Label33_Click()
Set sh = Sheets("CARİ")
msgbox WorksheetFunction.Sum(sh.Range("ed2:ed65536"))
 
tesekkurler
 
Geri
Üst