Kod kısaltması hakkında Yardım

Katılım
26 Ocak 2009
Mesajlar
60
Excel Vers. ve Dili
excel 2003
türkçe
Değerli arkadaşlar aşağıdaki kodları kısaltmanın yolu varmı. daha bu kodlar toplam 90 tane olacak. Aynı sırayı takip ediyorlar.
If Label21.Object <> "" Then
TextBox4.BackColor = vbgrey
TextBox4.Enabled = False
End If
If Label22.Object <> "" Then
TextBox5.BackColor = vbgrey
TextBox5.Enabled = False
End If
If Label23.Object <> "" Then
TextBox6.BackColor = vbgrey
TextBox6.Enabled = False
End If
If Label24.Object <> "" Then
TextBox7.BackColor = vbgrey
TextBox7.Enabled = False
End If
If Label25.Object <> "" Then
TextBox8.BackColor = vbgrey
TextBox8.Enabled = False
End If
If Label26.Object <> "" Then
TextBox9.BackColor = vbgrey
TextBox9.Enabled = False
End If
 

hamitcan

Uzman
Uzman
Katılım
1 Temmuz 2004
Mesajlar
7,759
Excel Vers. ve Dili
Excel 2019 Türkçe
Bence bir örnek dosya hazırlayın. Yapmak istediğinizi de kısaca açıklayın.
 
Üst