🎨 UserForm Nedir?
Excel içinde kendi penceresini (form) oluşturabilirsin. "Müşteri Bilgisi" formunu aç, isim ve email gir, "Kaydet"e bas → Veriler otomatik Excel'e eklenir!
🛠️ UserForm Oluşturma
Adım 1: Alt+F11 → VBA Editörü
Adım 2: Proje sağ tıkla → Insert → UserForm
Adım 3: Form tasarla (Label, TextBox, Button ekleme)
💡 Form Elemanları
Label: Metin gösterir (etiket)
TextBox: Kullanıcı veri girer
ComboBox: Açılır liste
CommandButton: Buton (Kaydet, İptal vb.)
⚙️ Veri Kaydetme
Kaydet butonuna VBA kodu ekleme:
Private Sub CommandButton1_Click()
Sheets("Veriler").Range("A" & Rows.Count).End(xlUp).Row + 1).Value = TextBox1.Value
MsgBox "Kayıt yapıldı!"
Me.Hide
End Sub
TextBox1'deki veri, "Veriler" sayfasının sonuna eklenir!
🎪 Challenge
Müşteri Formu: Ad, Email, Telefon TextBox'ları. Kaydet butonu. Veriler Sheet'e eklenmeli!
Henüz yorum yapılmamış. İlk yorumu sen yap!
Yorum Yap