DOSYA İndirmek/Yüklemek için ÜCRETLİ ALTIN ÜYELİK Gereklidir!
Altın Üyelik Hakkında Bilgi
Alış satış ve kasa bu üç dosyadan isme göre rapor almak
istiyorum yardımcı olursanız sevınırım
Sub Raporla()
Dim c As Range, sat As Long, Adr As Variant, i As Integer
Application.ScreenUpdating = False
Sheets("RAPOR").Select
Rows("2:" & Rows.Count).Clear
Sheets("KASA").Range("B4:N5").Copy Range("A2")
sat = 4
For i = 1 To Worksheets.Count
With Sheets(i)
If .Name <> "RAPOR" Then
Set c = .[[COLOR=blue]F:F[/COLOR]].Find(Range("[COLOR=red]A1[/COLOR]"), , xlValues, xlWhole)
If Not c Is Nothing Then
Adr = c.Address
Do
.Range("B" & c.Row, "N" & c.Row).Copy Range("A" & sat)
sat = sat + 1
Set c = .[[COLOR=blue]F:F[/COLOR]].FindNext(c)
Loop While Not c Is Nothing And c.Address <> Adr
End If
End If
End With
Next i
Cells.EntireColumn.AutoFit
Application.ScreenUpdating = True
End Sub
Private Sub CommandButton1_Click()
Dim sat As Long, sh As Worksheet, sf()
Sheets("RAPOR").Select
Range("B5:N" & Rows.Count).Clear
Application.ScreenUpdating = False
sf = Array("", "ALIŞ", "SATIŞ", "KASA")
For i = 1 To 3
Set sh = Sheets(sf(i))
sh.Range("B4").AutoFilter
sh.Range("B4").AutoFilter field:=5, Criteria1:=TextBox1.Text & "*"
If WorksheetFunction.Subtotal(103, sh.Range("B5:B" & sh.Rows.Count)) > 0 Then
sat = Cells(Rows.Count, "B").End(xlUp).Row + 1
sh.Range("B4").CurrentRegion.Offset(1, 0).Copy
Range("B" & sat).PasteSpecial (xlPasteValuesAndNumberFormats)
End If
Application.CutCopyMode = False
sh.Range("B4").AutoFilter
Set sh = Nothing
Next i
Application.ScreenUpdating = True
Unload Me
MsgBox "İşlem tamamlanmıştır." & vbLf & "evrengizlen@hotmail.com", vbOKOnly + vbInformation
End Sub