اذهب الي المحتوي
أوفيسنا
بحث مخصص من جوجل فى أوفيسنا
Custom Search

الردود الموصى بها

قام بنشر

ارجو المساعدة فى معرفة الخطأ البرمجى فى الكود التالى

 

Private Sub TextBox2_Change()
Dim ws As Worksheet
Dim x As Long
Set ws = Worksheets("Sheet7")
x = TextBox2

TextBox3 = Application.WorksheetFunction.VLookup(x, ws.Range("a2:g551"), 2, 0)
End Sub

 

 

pro.rar

قام بنشر (معدل)

عندك خطا في كود الترحيل الى خيار "هالك" قم بتغيير 2 الى 3 في

 

If OptionButton3.Value = True Then

Set ws = Worksheets("whs")
iRow = ws.Cells(Rows.Count, 1) _
  .End(xlUp).Offset(1, 0).Row
If OptionButton1.Value = True Then
ws.Cells(iRow, 1).Value = Me.TextBox1.Value
ws.Cells(iRow, 2).Value = Me.ComboBox1.Value
ws.Cells(iRow, 3).Value = Me.TextBox3.Value
ws.Cells(iRow, 4).Value = Me.TextBox4.Value
Else
If OptionButton2.Value = True Then
ws.Cells(iRow, 1).Value = Me.TextBox1.Value
ws.Cells(iRow, 2).Value = Me.ComboBox1.Value
ws.Cells(iRow, 3).Value = Me.TextBox3.Value
ws.Cells(iRow, 5).Value = Me.TextBox4.Value
Else
If OptionButton3.Value = True Then
ws.Cells(iRow, 1).Value = Me.TextBox1.Value
ws.Cells(iRow, 2).Value = Me.ComboBox1.Value
ws.Cells(iRow, 3).Value = Me.TextBox3.Value
ws.Cells(iRow, 6).Value = Me.TextBox4.Value
تم تعديل بواسطه عبد الله بولنوار

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

زائر
اضف رد علي هذا الموضوع....

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • اضف...

Important Information