hello all,

Thanks for your help,

I need this macro to assist in a project and have not used macros...ever! most of my excel has been simple. I spent the past 16 hours trying to learn the macros and how to set up everything but i am stuck. I have programmed before and really enjoyed it so I would love to understand any help you are able to give me.

Ok so to begin i need to be able to pull data from a specific sheet of which the file is stored on a shared networked folder. A prompt will be needed to ask the user what date they would like to search for in the form of xx/yy/20zz. once the user enters the date the program will have to look down column B and find the set of all rows that contain this date. All rows must then be pulled to the new excel workbook and placed into a sheet labeled "master data_date". the macro must then search column I for names of 28 different stain colors. The number of rows for each stain color must be added and placed into the appropriate material sheet. each material has multiple colors. below here is the programming i have taught myself over the past two days but i just cant figure out how to get everything to come together and im probably not doing everything correctly. Therefore i have come for some assistance

Again thank you so much!!

some of the lines are commented out because I was testing other smaller parts.



'Sub PullDailyDoorReorder()
'
''dimension variables
'Dim color, dates As String
'
''loop for as many colors as requested
'Do
''Allow user to input specific color and date
'dates = InputBox("Please enter the date you would like to pull data from: xx/yy/20zz", "Data date request")
'color = InputBox("Please enter color you desire to move to a material sheet", "Color Selection")
'
'
''Set location variables
'PATH = "G:\Shared\Extra Door File"
'FILENAME = "Style Size added NEW Hot Tags Doors-Fronts 2013.xlsm"
'SHEETNAME = "Master data"
'
''looking in sheetname find the date i have requested
'Rng = xlvaues
'a = Find(dates)
'
''reference my "a" variable to know what cells
'ref = a
''retrieve data
'RETRIEVE = "='" & PATH & "[" & FILENAME & "]" & SHEETNAME & "'!" & ref & ""
'
'Loop Until color = "" Or dates = ""
'
'
'End Sub
'
'Function AutoFilter_Ends_With()
''Put the * mark before the word in which you would like to filter for this macro
'
'Range("A1").AutoFilter Field:=1, Criteria1:="*Dates"
'
'End Function


Sub PullDailyDoorReorder()
Dim PATH, FILENAME, SHEETNAME, CELL, i


PATH = "G:\Shared\Extra Door File"
FILENAME = "Style Size added NEW Hot Tags Doors-Fronts 2013.xlsm"
SHEETNAME = "Master data"
Application.ScreenUpdating = False
For r = 1 To 100
For c = 1 To 20
REF = Cells(r, c).Address
Cells(r, c) = GetValue(PATH, FILENAME, SHEETNAME, REF)
Next c
Next r
Application.ScreenUpdating = True
DateEnter = InputBox("Please enter the date you would like to search")


' For i = 1 To 2
' Range("B" & i) = RETRIEVE(PATH, FILENAME, SHEETNAME, "A" & i)
' Next i
End Sub

'Function RETRIEVE(PATH, FILENAME, SHEETNAME, CELL)
'
' RETRIEVE = "='" & PATH & "[" & FILENAME & "]" & SHEETNAME & "'!" & CELL & ""
'
'End Function


'Option Explicit
'Sub PullDailyDoorReorder()
''dimension variables
'Dim v1, v2, v3, v4, v5, v6, v7, v8 As String, res, sh, myrange As Range
'
''update screen while running = false
'Application.ScreenUpdating = False:
''input box
'vl = Application.InputBox("Enter color name from Column I", Type:=2):
'
'
'If vl = "" Then Exit Sub
'
'Set sh = ActiveSheet: With sh: Set myrange = .Range(.[a2], .Cells(Rows.Count, "k").End(xlUp))
'Set res = .Range(.[b3], Cells(Rows.Count, "b").End(xlUp)).Find(vl, , xlValues, xlWhole)
' If Not res Is Nothing Then
' On Error Resume Next: With Sheets(vl)
' If Err.Number <> 0 Then
' Sheets.Add.Name = vl
' Else
' MsgBox "Sheets " & vl & " already exists. Change input value and try again", vbCritical: Exit Sub
' End If:
' End With: myrange.AutoFilter 2, vl: .AutoFilter.Range.Copy Sheets(vl).[a1]: myrange.AutoFilter
'End If:
'End With:
''update screen with final results
'Application.ScreenUpdating = True:
'End Sub