alexa-tracking

Main Content

1024
1024
KASKUS
51
244
https://www.kaskus.co.id/thread/531f956aa2cb17cb458b456b/mau-belajar-vb-tolong-bantu-gan
Mau belajar VB, tolong bantu gan
Mau belajar VB, tolong bantu gan
itu gimana caranya biar kalo di klik semua, tulisan di checkboxnya keluar di kolom yang samping itu, ane udah nyoba tapi ga bisa keluar semua. kalo di check semua yang muncul cuma yang terakhir doang

PLEASE HELPemoticon-Mewek
if cekbox1.cek=true and cekbox2.cek=true and cekbox3.cek=true then
textbox1.text=cekbox1.text & cekbox2.text & cekbox3.text
end if

semoga membantu emoticon-Smilie
asumsi nama nama control

tombol : CommandButton1
cek box : CheckBox1,CheckBox2,CheckBox3
text box : Text1

koding saat event CommandButton1 di klik
Code:

Private Sub CummandButton1_Click()
[INDENT]
Dim sBuff as String

sBuff = Iif(Check1.check,Check1.Caption & ",","") & Iif(Check2.check,Check2.Caption & ",","") & Iif(Check3.check,Check3.Caption,"")

If Trim(sBuff) = "" Then
[INDENT]
Text1.Text = "Entre punya pacar ?"
[/INDENT]
Else
[INDENT]
Text1.Text = "Ternyata entre " & trim(sBuff)
[/INDENT]
End If
[/INDENT]
End Sub


dicoba dulu ye gan, udah lama ga buka VB6 soale emoticon-Ngakak
Quote:Original Posted By nunuyasha
asumsi nama nama control

tombol : CommandButton1
cek box : CheckBox1,CheckBox2,CheckBox3
text box : Text1

koding saat event CommandButton1 di klik
Code:

Private Sub CummandButton1_Click()
[INDENT]
Dim sBuff as String

sBuff = Iif(Check1.check,Check1.Caption & ",","") & Iif(Check2.check,Check2.Caption & ",","") & Iif(Check3.check,Check3.Caption,"")

If Trim(sBuff) = "" Then
[INDENT]
Text1.Text = "Entre punya pacar ?"
[/INDENT]
Else
[INDENT]
Text1.Text = "Ternyata entre " & trim(sBuff)
[/INDENT]
End If
[/INDENT]
End Sub


dicoba dulu ye gan, udah lama ga buka VB6 soale emoticon-Ngakak


oke makasih gan, udah jadi kok programnya cuma salah nulis doang tadi, sudah ngantuk soalnya