I want to open in a macro workbooks with a different name and number, I would like to add a variable into that macro that I can type in before running the said macro. i.e. C:\temp\NorthSeaArea1.txt, the name variable will be the "NorthSeaArea" and the number variable will be the "1", this also can vary between 1 up to 7, when that is set then I could run the rest of the macro which copies 2 cells from one workbook to another.
Can any body tell me what the solution is to this problem?
Thanks for your help.
DSB
Hi
Here's one way
Another would be to use theCode:Workbooks.Open Filename:="c:\temp\" & InputBox("What is the file name") & InputBox("What is the number") & ".txt"
approach where the user can move to the relevant file.Code:getname = Application.GetOpenFilename
rylo
THanks I'll give it a go, and let you know
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks