Dear All
kindly find attached workbook have 2 sheets
1st sheet is as database
2nd sheet is for analysis
required
call data from database sheet to analysis sheet based on the criteria and condition in the sheet
thanks
Attachment :
Call Data.xls
Dear All
kindly find attached workbook have 2 sheets
1st sheet is as database
2nd sheet is for analysis
required
call data from database sheet to analysis sheet based on the criteria and condition in the sheet
thanks
Attachment :
Call Data.xls
any help ????
any help ??
Not with as sparse a description as that and no sample workbook.
____________________________________________
Nihil simul inventum est et perfectum
Abusus non tollit usum
Last night I dreamed of a small consolation enjoyed only by the blind: Nobody knows the trouble I've not seen!
James Thurber
I cant understand you my friend
Any Help Guys ????????
Try this
Option Explicit Sub Calls_Click() Dim rData As Range, rFilters As Range Dim wsAnalysis As Worksheet Dim iDatabase As Long, iAnalysis As Long, i As Long Application.ScreenUpdating = False Set rData = Worksheets("Database").Cells(1, 2).CurrentRegion Set wsAnalysis = Worksheets("Analysis") Set rFilters = wsAnalysis.Range("B1:D10") With wsAnalysis Range(.Rows(12), Rows(.Rows.Count)).ClearContents End With iAnalysis = 12 ' 1 2 3 4 5 6 7 8 9 'Period Type Date Category Description Amount Marker Tag Ref For iDatabase = 2 To rData.Rows.Count '3 Type '4 Date C-D '5 Category '6 Description '7 Amount '8 Marker '9 Tag '10 Ref With rData.Rows(iDatabase) For i = 2 To 10 Select Case i Case 1, 3, 5, 6, 7, 8, 9, 10 If Len(rFilters.Cells(i, 2).Value) > 0 And .Cells(i - 1).Value <> rFilters.Cells(i, 2).Value Then GoTo GetNext Case 2, 4 If Len(rFilters.Cells(i, 2).Value) > 0 And .Cells(i - 1).Value < rFilters.Cells(i, 2).Value Then GoTo GetNext If Len(rFilters.Cells(i, 3).Value) > 0 And .Cells(i - 1).Value > rFilters.Cells(i, 3).Value Then GoTo GetNext End Select Next i .Copy wsAnalysis.Cells(iAnalysis, 2) iAnalysis = iAnalysis + 1 End With GetNext: Next iDatabase Application.ScreenUpdating = True End Sub
---------------------------------------------------------------------------------------------------------------------
Paul
Remember: Tell us WHAT you want to do, not HOW you think you want to do it
1. Use [CODE] ....[/CODE ] Tags for readability
[CODE]PasteYourCodeHere[/CODE ] -- (or paste your code, select it, click [#] button)
2. Upload an example
Go Advanced / Attachments - Manage Attachments / Add Files / Select Files / Select the file(s) / Upload Files / Done
3. Mark the thread as [Solved] when you have an answer
Thread Tools (on the top right corner, above the first message)
4. Read the Forum FAQ, especially the part about cross-posting in other forums
http://www.vbaexpress.com/forum/faq...._new_faq_item3
Dear Paul_Hosslerthank you very much for your support iam very thankfulwhats your opinion if i make anew sheet as shart of account , we will make for each category a number then we can filter with 2 criteria Is it right ????Thankskero