abdulbarimd
New Member
- Joined
- Aug 23, 2013
- Messages
- 3
Hi All,
Request your help in defining a macro for a command button which helps me to Autofilter and Copy from a SourceData file (w/o opening) which is stored at a location in d-drive and while pasting into another sheet (master file will have the sheets which are already created for the filtered values) it should replace the existing data in the defined range (A2:Z10).
Requirement description is as below:-
1. I have a file named as "RBD - <dd-mmm-yy>" stored at a particular location in D-Drive
2. In the master file, when I select a cell (say B2) and enter the date (in dd-mmm-yy format and is same as that of the sourcedata file name in point 1) and click the command button (Refresh) to refresh the data, macro should reach out to the stored file (sourcedata file in D-Drive) which is in the defined date format and read the contents, auto filter on column D (with filter value as Project Name) and copy the contents/rows related to that project (which are already created for those filter values) into the master file.
3. In this process, it should also replace the existing data in the rows of the sheet in master file.
4. If any New Filter Value is added in that SourceData sheet, then in that case, it should automatically create a new sheet with that Filtered value and copy the data as above.
5. Instead of point 2 where the macro should reach the file automatically having the date format, it would also work if it prompts me to browse and select the sourcedata file in my computer. Once the file is browsed and selected, it should not open, but instead, it should automatically filter, copy and paste the contents as mentioned above.
Please help me here in this regards....</dd-mmm-yy>
Request your help in defining a macro for a command button which helps me to Autofilter and Copy from a SourceData file (w/o opening) which is stored at a location in d-drive and while pasting into another sheet (master file will have the sheets which are already created for the filtered values) it should replace the existing data in the defined range (A2:Z10).
Requirement description is as below:-
1. I have a file named as "RBD - <dd-mmm-yy>" stored at a particular location in D-Drive
2. In the master file, when I select a cell (say B2) and enter the date (in dd-mmm-yy format and is same as that of the sourcedata file name in point 1) and click the command button (Refresh) to refresh the data, macro should reach out to the stored file (sourcedata file in D-Drive) which is in the defined date format and read the contents, auto filter on column D (with filter value as Project Name) and copy the contents/rows related to that project (which are already created for those filter values) into the master file.
3. In this process, it should also replace the existing data in the rows of the sheet in master file.
4. If any New Filter Value is added in that SourceData sheet, then in that case, it should automatically create a new sheet with that Filtered value and copy the data as above.
5. Instead of point 2 where the macro should reach the file automatically having the date format, it would also work if it prompts me to browse and select the sourcedata file in my computer. Once the file is browsed and selected, it should not open, but instead, it should automatically filter, copy and paste the contents as mentioned above.
Please help me here in this regards....</dd-mmm-yy>