Hai Prazt. Ini saya kasi contohnya, semoga anda bisa memahaminya. TerimaKasih.
Pada Kamis, 29 September 2016 12:57, "[email protected] [belajar-excel]"
<[email protected]> menulis:
Karena belum pahan mas toby, tapi masih nyoba nyoba pakai option button
cuman belum jadi..kalau pakai option button terus ada beberapa grup gmn ya
cekripnya..? Sent from Mail for Windows 10 From:
mailto:[email protected]
Sent: Kamis, 29 September 2016 11.21
To: [email protected]
Subject: Bls: [belajar-excel] menampilkan data di listbox sesuai
apayangdicheckbox Hai Prazt, Kenapa ngga pake Option Button dengan
kombinasi frame aja kalo memang sulit menggunakan kombinasi Checkbox.
TerimaKasih. Pada Kamis, 29 September 2016 9:55, "[email protected]
[belajar-excel]" <[email protected]> menulis: Mohon di koreksi
Mr.Kid, kesalahan disebelah mana dan pembetulannya gimana pada cekrip
berikut.?? Maaf belum begitu bias hehehe.. Private bChange As Boolean,
chkGroup1(1 To 5), chkGroup2(6 To 8) As Control Private Sub
ListBox1_DblClick(ByVal Cancel As MSForms.ReturnBoolean) TextBox14.Value =
ListBox1.List(ListBox1.ListIndex, 2) TextBox15.Value =
ListBox1.List(ListBox1.ListIndex, 5)End Sub Private Sub TextBox2_Change()If
TextBox2.Value = "" Or TextBox12.Value = "" ThenTextBox13.Value = ""Exit SubEnd
IfTextBox13.Value = Format(CDbl(TextBox12.Value) * CDbl(TextBox12.Value),
"#,##0")End SubPrivate Sub UserForm_Initialize() bChange = False Set
chkGroup1(1) = chk1 Set chkGroup1(2) = chk2 Set chkGroup1(3) = chk3
Set chkGroup1(4) = chk4 Set chkGroup1(5) = chk5 Set chkGroup2(6) = chk6
Set chkGroup2(7) = chk7 Set chkGroup2(8) = chk8 With
OpnChk.ListBox1.ColumnCount = 6.ColumnHeads = True.ColumnWidths =
"30;55;100;70;90".RowSource = "List_dbB1".MultiSelect =
fmMultiSelectSingle.BoundColumn = 0 End WithEnd Sub Private Sub chk1_Change()
ChangeChk 1End Sub Private Sub chk2_Change() ChangeChk 2End Sub Private Sub
chk3_Change() ChangeChk 3End SubPrivate Sub chk4_Change() ChangeChk 4End
Sub Private Sub chk5_Change() ChangeChk 5End SubPrivate Sub chk6_Change()
ChangeChk 6End SubPrivate Sub chk7_Change() ChangeChk 7End SubPrivate Sub
chk8_Change() ChangeChk 8End Sub Private Sub ChangeChk(lIdx As Long) Dim
lChk As Long, bState As Boolean If bChange Then Exit Sub End
If If chkGroup1(lIdx).Value Then bChange = True For lChk =
1 To 5 If lChk <> lIdx Then 'selain checkbox yang diubah user
chkGroup1(lChk).Value = False End If Next lChk
bChange = False Else 'kalau mau set agar selalu ada yang di-checked,
setidaknya checkbox setelahnya If lIdx = 5 Then lIdx = 0
End If chkGroup1(lIdx + 1) = True End If'di bawah ini untuk grup 2
If chkGroup2(lIdx).Value Then bChange = True For lChk = 6
To 8 If lChk <> lIdx Then 'selain checkbox yang diubah user
chkGroup2(lChk).Value = False End If Next lChk
bChange = False Else 'kalau mau set agar selalu ada yang di-checked,
setidaknya checkbox setelahnya If lIdx = 3 Then lIdx = 0
End If chkGroup2(lIdx + 1) = True End IfEnd Sub Sent from Mail for
Windows 10 From: mailto:[email protected]
Sent: Kamis, 29 September 2016 09.29
To: BeExcel
Subject: Re: [belajar-excel] menampilkan data di listbox sesuai apa
yangdicheckbox Buat variabel grup dan prosedur changechk untuk masing-masing
grup checkbox dengan nama variabel dan prosedur yang unique On Thu, Sep 29,
2016 at 9:08 AM, [email protected] [belajar-excel]
<[email protected]> wrote:
Terima kasih Mr.Kid, kalau saya amati dicontoh tersebut untuk chekboxnya ada
satu grup, kalau ada beberap group checkbox cekripnya gimana Mr.Kir..? saya
coba membuat 3 group checkboxBerikut cekrip dari Mr.Kid Private bChange As
Boolean, chkGroup(1 To 3) As Control Private Sub UserForm_Initialize()
bChange = False Set chkGroup(1) = chk1 Set chkGroup(2) = chk2 Set
chkGroup(3) = chk3End Sub Private Sub chk1_Change() ChangeChk 1End Sub
Private Sub chk2_Change() ChangeChk 2End Sub Private Sub chk3_Change()
ChangeChk 3End Sub Private Sub ChangeChk(lIdx As Long) Dim lChk As Long,
bState As Boolean If bChange Then Exit Sub End If If
chkGroup(lIdx).Value Then bChange = True For lChk = 1 To 3
If lChk <> lIdx Then 'selain checkbox yang diubah user
chkGroup(lChk).Value = False End If Next lChk bChange
= False Else 'kalau mau set agar selalu ada yang di-checked, setidaknya
checkbox setelahnya If lIdx = 3 Then lIdx = 0 End If
chkGroup(lIdx + 1) = True End IfEnd Sub Sent from Mail for Windows 10
From: mailto:[email protected]
Sent: Sabtu, 24 September 2016 15.49
To: BeExcel
Subject: Re: [belajar-excel] menampilkan data di listbox sesuai apa yang
dicheckbox Coba lihat file yang ada disini.Regards,Kid 2016-09-24 9:54
GMT+07:00 [email protected] [belajar-excel] <[email protected]>:
Selamat siang sedulur dan para masterMohon bantuannya bagaimana cara
menampildan data di listbox sesuai pilihan yang ada pada checkbox, serta
checkbox dengan cara bergantian dengan kata lain checkbox hanya bias di check
salah satu...file berikut saya lampirkan dan sudah ada sedikit cekripnya yang
saya copas dari beberapa web dan saya modif sedikit sedikit karena masih belum
mudeng dengan macro VBA.. Sent from Mail for Windows 10
#yiv7830388108 #yiv7830388108 -- #yiv7830388108ygrp-mkp {border:1px
solid #d8d8d8;font-family:Arial;margin:10px 0;padding:0 10px;}#yiv7830388108
#yiv7830388108ygrp-mkp hr {border:1px solid #d8d8d8;}#yiv7830388108
#yiv7830388108ygrp-mkp #yiv7830388108hd
{color:#628c2a;font-size:85%;font-weight:700;line-height:122%;margin:10px
0;}#yiv7830388108 #yiv7830388108ygrp-mkp #yiv7830388108ads
{margin-bottom:10px;}#yiv7830388108 #yiv7830388108ygrp-mkp .yiv7830388108ad
{padding:0 0;}#yiv7830388108 #yiv7830388108ygrp-mkp .yiv7830388108ad p
{margin:0;}#yiv7830388108 #yiv7830388108ygrp-mkp .yiv7830388108ad a
{color:#0000ff;text-decoration:none;}#yiv7830388108 #yiv7830388108ygrp-sponsor
#yiv7830388108ygrp-lc {font-family:Arial;}#yiv7830388108
#yiv7830388108ygrp-sponsor #yiv7830388108ygrp-lc #yiv7830388108hd {margin:10px
0px;font-weight:700;font-size:78%;line-height:122%;}#yiv7830388108
#yiv7830388108ygrp-sponsor #yiv7830388108ygrp-lc .yiv7830388108ad
{margin-bottom:10px;padding:0 0;}#yiv7830388108 #yiv7830388108actions
{font-family:Verdana;font-size:11px;padding:10px 0;}#yiv7830388108
#yiv7830388108activity
{background-color:#e0ecee;float:left;font-family:Verdana;font-size:10px;padding:10px;}#yiv7830388108
#yiv7830388108activity span {font-weight:700;}#yiv7830388108
#yiv7830388108activity span:first-child
{text-transform:uppercase;}#yiv7830388108 #yiv7830388108activity span a
{color:#5085b6;text-decoration:none;}#yiv7830388108 #yiv7830388108activity span
span {color:#ff7900;}#yiv7830388108 #yiv7830388108activity span
.yiv7830388108underline {text-decoration:underline;}#yiv7830388108
.yiv7830388108attach
{clear:both;display:table;font-family:Arial;font-size:12px;padding:10px
0;width:400px;}#yiv7830388108 .yiv7830388108attach div a
{text-decoration:none;}#yiv7830388108 .yiv7830388108attach img
{border:none;padding-right:5px;}#yiv7830388108 .yiv7830388108attach label
{display:block;margin-bottom:5px;}#yiv7830388108 .yiv7830388108attach label a
{text-decoration:none;}#yiv7830388108 blockquote {margin:0 0 0
4px;}#yiv7830388108 .yiv7830388108bold
{font-family:Arial;font-size:13px;font-weight:700;}#yiv7830388108
.yiv7830388108bold a {text-decoration:none;}#yiv7830388108 dd.yiv7830388108last
p a {font-family:Verdana;font-weight:700;}#yiv7830388108 dd.yiv7830388108last p
span {margin-right:10px;font-family:Verdana;font-weight:700;}#yiv7830388108
dd.yiv7830388108last p span.yiv7830388108yshortcuts
{margin-right:0;}#yiv7830388108 div.yiv7830388108attach-table div div a
{text-decoration:none;}#yiv7830388108 div.yiv7830388108attach-table
{width:400px;}#yiv7830388108 div.yiv7830388108file-title a, #yiv7830388108
div.yiv7830388108file-title a:active, #yiv7830388108
div.yiv7830388108file-title a:hover, #yiv7830388108 div.yiv7830388108file-title
a:visited {text-decoration:none;}#yiv7830388108 div.yiv7830388108photo-title a,
#yiv7830388108 div.yiv7830388108photo-title a:active, #yiv7830388108
div.yiv7830388108photo-title a:hover, #yiv7830388108
div.yiv7830388108photo-title a:visited {text-decoration:none;}#yiv7830388108
div#yiv7830388108ygrp-mlmsg #yiv7830388108ygrp-msg p a
span.yiv7830388108yshortcuts
{font-family:Verdana;font-size:10px;font-weight:normal;}#yiv7830388108
.yiv7830388108green {color:#628c2a;}#yiv7830388108 .yiv7830388108MsoNormal
{margin:0 0 0 0;}#yiv7830388108 o {font-size:0;}#yiv7830388108
#yiv7830388108photos div {float:left;width:72px;}#yiv7830388108
#yiv7830388108photos div div {border:1px solid
#666666;min-height:62px;overflow:hidden;width:62px;}#yiv7830388108
#yiv7830388108photos div label
{color:#666666;font-size:10px;overflow:hidden;text-align:center;white-space:nowrap;width:64px;}#yiv7830388108
#yiv7830388108reco-category {font-size:77%;}#yiv7830388108
#yiv7830388108reco-desc {font-size:77%;}#yiv7830388108 .yiv7830388108replbq
{margin:4px;}#yiv7830388108 #yiv7830388108ygrp-actbar div a:first-child
{margin-right:2px;padding-right:5px;}#yiv7830388108 #yiv7830388108ygrp-mlmsg
{font-size:13px;font-family:Arial, helvetica, clean, sans-serif;}#yiv7830388108
#yiv7830388108ygrp-mlmsg table {font-size:inherit;font:100%;}#yiv7830388108
#yiv7830388108ygrp-mlmsg select, #yiv7830388108 input, #yiv7830388108 textarea
{font:99% Arial, Helvetica, clean, sans-serif;}#yiv7830388108
#yiv7830388108ygrp-mlmsg pre, #yiv7830388108 code {font:115%
monospace;}#yiv7830388108 #yiv7830388108ygrp-mlmsg *
{line-height:1.22em;}#yiv7830388108 #yiv7830388108ygrp-mlmsg #yiv7830388108logo
{padding-bottom:10px;}#yiv7830388108 #yiv7830388108ygrp-msg p a
{font-family:Verdana;}#yiv7830388108 #yiv7830388108ygrp-msg
p#yiv7830388108attach-count span {color:#1E66AE;font-weight:700;}#yiv7830388108
#yiv7830388108ygrp-reco #yiv7830388108reco-head
{color:#ff7900;font-weight:700;}#yiv7830388108 #yiv7830388108ygrp-reco
{margin-bottom:20px;padding:0px;}#yiv7830388108 #yiv7830388108ygrp-sponsor
#yiv7830388108ov li a {font-size:130%;text-decoration:none;}#yiv7830388108
#yiv7830388108ygrp-sponsor #yiv7830388108ov li
{font-size:77%;list-style-type:square;padding:6px 0;}#yiv7830388108
#yiv7830388108ygrp-sponsor #yiv7830388108ov ul {margin:0;padding:0 0 0
8px;}#yiv7830388108 #yiv7830388108ygrp-text
{font-family:Georgia;}#yiv7830388108 #yiv7830388108ygrp-text p {margin:0 0 1em
0;}#yiv7830388108 #yiv7830388108ygrp-text tt {font-size:120%;}#yiv7830388108
#yiv7830388108ygrp-vital ul li:last-child {border-right:none
!important;}#yiv7830388108
PRAZT_1.xlsm
Description: application/vnd.ms-excel.sheet.macroenabled.12

