Private Sub ComboBox1_Change()
Dim bul As Range, syf As Worksheet
Set syf = Worksheets("AŞIM")
For Each bul In syf.Range("b2:b" & syf.Range("b65536").End(3).Row)
If bul.Value = ComboBox1.Text Then
TextBox1.Value = bul.Offset(0, 0)
TextBox2.Value = bul.Offset(0, 1)
TextBox3.Value = bul.Offset(0, 2)
TextBox4.Value = bul.Offset(0, 3)
TextBox5.Value = bul.Offset(0, 4)
Exit For
End If
Next bul
If TextBox2.Value = Empty Then
TextBox2.Value = ("EKSİK BLOKE YOKTUR")
End If
If TextBox5.Value = Empty Then
TextBox5.Value = ("AŞIM YOKTUR")
End If
End Sub
Private Sub TextBox2_Change()
Me.TextBox2.Value = Format(Me.TextBox2.Value, "###,###")
End Sub
Private Sub TextBox3_Change()
Me.TextBox3.Value = Format(Me.TextBox3.Value, "###,###")
End Sub
Private Sub TextBox4_Change()
Me.TextBox4.Value = Format(Me.TextBox4.Value, "###,###")
End Sub
Private Sub TextBox5_Change()
Me.TextBox5.Value = Format(Me.TextBox5.Value, "###,###")
End Sub
Private Sub UserForm_Activate()
ComboBox1.RowSource = "AŞIM!B5:B" & WorksheetFunction.CountA(Worksheets("AŞIM").Range("B1:B6536"))
End Sub
Private Sub UserForm_Initialize()
With UserForm1.ComboBox1
.Text = "Müşteri İsmini Buradan Seçiniz"
End With
End Sub
yukarıdaki kodu yazıp çalıştırdığımda Excel dosyasında 1.254.360,2 olan rakan Textbox geçirildiğinde 12.543.602 olarak atıyor. Nasıl düzeltitirm.
Dim bul As Range, syf As Worksheet
Set syf = Worksheets("AŞIM")
For Each bul In syf.Range("b2:b" & syf.Range("b65536").End(3).Row)
If bul.Value = ComboBox1.Text Then
TextBox1.Value = bul.Offset(0, 0)
TextBox2.Value = bul.Offset(0, 1)
TextBox3.Value = bul.Offset(0, 2)
TextBox4.Value = bul.Offset(0, 3)
TextBox5.Value = bul.Offset(0, 4)
Exit For
End If
Next bul
If TextBox2.Value = Empty Then
TextBox2.Value = ("EKSİK BLOKE YOKTUR")
End If
If TextBox5.Value = Empty Then
TextBox5.Value = ("AŞIM YOKTUR")
End If
End Sub
Private Sub TextBox2_Change()
Me.TextBox2.Value = Format(Me.TextBox2.Value, "###,###")
End Sub
Private Sub TextBox3_Change()
Me.TextBox3.Value = Format(Me.TextBox3.Value, "###,###")
End Sub
Private Sub TextBox4_Change()
Me.TextBox4.Value = Format(Me.TextBox4.Value, "###,###")
End Sub
Private Sub TextBox5_Change()
Me.TextBox5.Value = Format(Me.TextBox5.Value, "###,###")
End Sub
Private Sub UserForm_Activate()
ComboBox1.RowSource = "AŞIM!B5:B" & WorksheetFunction.CountA(Worksheets("AŞIM").Range("B1:B6536"))
End Sub
Private Sub UserForm_Initialize()
With UserForm1.ComboBox1
.Text = "Müşteri İsmini Buradan Seçiniz"
End With
End Sub
yukarıdaki kodu yazıp çalıştırdığımda Excel dosyasında 1.254.360,2 olan rakan Textbox geçirildiğinde 12.543.602 olarak atıyor. Nasıl düzeltitirm.