fastballfreddy
Board Regular
- Joined
- Jan 13, 2015
- Messages
- 60
- Office Version
- 2016
- Platform
- Windows
I have a code to input date of file for it to open (start of the code below).
I have a main folder called Data that has folders for each previous day's date. I want a code that i can input the folder's name that is in Data to then input the file name of the file in that folder. For example in the Data folder I have a folder named 07-09-2024. I want to input that folder name in a popup box to then grab the file in there.
I have a main folder called Data that has folders for each previous day's date. I want a code that i can input the folder's name that is in Data to then input the file name of the file in that folder. For example in the Data folder I have a folder named 07-09-2024. I want to input that folder name in a popup box to then grab the file in there.
VBA Code:
Sub data()
Dim Loc As String
Dim Nme As String
Loc = "D:\Trackers\Data\Review"
Dim Result As Variant
Result = InputBox("Input date MMDDYY", "Date Picker"(
Nme = "Tracking Log " & Nme & ".xlsx"