Sub Hip_File_Open()
'
' Hip_File_Open Macro
fldr = "Q:\Workforce Planning and Allocation\HIP Files"
d = Dir(fldr & "*.xls") 'looks at all xls files in folder
Do While d <> "" 'd is a string containing the file name
d = Dir
Loop
End Sub
In the worksheet this macro is run from there is a list of numbers in column A. When the macro runs i need the macro to look through the file shown above looking for the number in cell A1. It will look through all the files, and if it finds the number it is looking for it will return the title of the workbook it found the number in. If it does not find the number in any of the work books it will bring back the result (not found)
What code is needed to do this?
Thanks
'
' Hip_File_Open Macro
fldr = "Q:\Workforce Planning and Allocation\HIP Files"
d = Dir(fldr & "*.xls") 'looks at all xls files in folder
Do While d <> "" 'd is a string containing the file name
d = Dir
Loop
End Sub
In the worksheet this macro is run from there is a list of numbers in column A. When the macro runs i need the macro to look through the file shown above looking for the number in cell A1. It will look through all the files, and if it finds the number it is looking for it will return the title of the workbook it found the number in. If it does not find the number in any of the work books it will bring back the result (not found)
What code is needed to do this?
Thanks