DOSYA İndirmek/Yüklemek için ÜCRETLİ ALTIN ÜYELİK Gereklidir!
Altın Üyelik Hakkında Bilgi
Private Sub L1_Change()
If L2.ListCount > 0 Then
For i = 0 To L2.ListCount - 1
If L2.List(i) = L1.Value Then
GoTo 10
End If
Next
End If
L2.AddItem L1.Value
10:
End Sub
Private Sub L2_Change()
Set s1 = Sheets("ÇEKLİST")
son = WorksheetFunction.Max(2, s1.Cells(Rows.Count, "B").End(3).Row)
Set con = VBA.CreateObject("adodb.Connection")
con.Open "provider=microsoft.ace.oledb.12.0;data source=" & _
ThisWorkbook.FullName & ";extended properties=""Excel 12.0;hdr=yes"""
L3.Clear
For i = 0 To L2.ListCount - 1
If L2.Selected(i) Then
sorgu = "select distinct İÇERİK from [ÇEKLİST$] where KONU='" & L2.List(i) & "'"
Set rs = con.Execute(sorgu)
L3.Column = rs.getrows
End If
Next
End Sub
Private Sub UserForm_Initialize()
Set s1 = Sheets("ÇEKLİST")
son = WorksheetFunction.Max(2, s1.Cells(Rows.Count, "B").End(3).Row)
Set con = VBA.CreateObject("adodb.Connection")
con.Open "provider=microsoft.ace.oledb.12.0;data source=" & _
ThisWorkbook.FullName & ";extended properties=""Excel 12.0;hdr=yes"""
sorgu = "select distinct KONU from [ÇEKLİST$] where KONU is not null"
Set rs = con.Execute(sorgu)
L1.Column = rs.getrows
End Sub
Option Explicit
Dim i As Integer
Private Sub chkAll_Click()
For i = 1 To lbxSheets.ListCount
Me.lbxSheets.Selected(i - 1) = Me.chkAll.Value
Next i
End Sub
Private Sub cmbCancel_Click()
Unload Me
End Sub
Private Sub cmbPrint_Click()
For i = 1 To Me.lbxSheets.ListCount
If Me.lbxSheets.Selected(i - 1) = True Then
If Me.chkPreview Then
Me.Hide
Sheets(Me.lbxSheets.List(i - 1, 0)).PrintPreview
Me.lbxSheets.Selected(i - 1) = False
Else
Sheets(Me.lbxSheets.List(i - 1, 0)).PrintOut
Me.lbxSheets.Selected(i - 1) = False
End If
End If
Next i
End Sub
Private Sub UserForm_Initialize()
Dim oWs As Worksheet
For Each oWs In Sheets
If oWs.Type = 3 Then 'Chart sheet
Me.lbxSheets.AddItem oWs.Name
'exclude empty sheets
ElseIf WorksheetFunction.CountA(oWs.Cells) > 0 Then
Me.lbxSheets.AddItem oWs.Name
End If
Next oWs
End Sub