I have the following code to open up two workbooks, it goes through the motion, but it doesn't actually open them up. I can't figure out what is wrong. Your help will be greatly appreciated.
Sub DAformat() 'Turn off warnings, etc. Application.ScreenUpdating = False Application.DisplayAlerts = False FileOpenNameTB = "False" FileSaveName = "False" GoodData = False Sat = False DAImport: FileOpenNameDA = Application.GetOpenFilename("Excel Files (*.xl*),*.xl*", 1, "Open DA Excel File") FileOpenNameDA = ActiveWorkbook.Name FileOpenNameTB = "False" FileSaveName = "False" GoodData = False Sat = False ETImport: FileOpenNameET = Application.GetOpenFilename("Excel Files (*.xl*),*.xl*", 1, "Open ET Excel File") FileOpenNameET = ActiveWorkbook.Name End Sub
Last edited by exc1967; 02-13-2012 at 09:11 AM.
Please put code tags around your code in accordance with the forum rules, then we can tell you.![]()
Good luck.
I apologize. I need some help here. I see the instructions, but when I go to advanced, I do not see how to add the tags. If I read it correctly, I need to add [#], but I do not see that anywhere. This is the first time I have posted code.
Edit your original post and put
[code]
before the code and then
[/code]
after the code, then save it.
Good luck.
I do not think it is, so I think it would be around a 2.
GetOpenFileName does merely that - it gets the name of a file to open, but it does not open it. You have to do that yourself.
FileOpenNameDA = Application.GetOpenFilename("Excel Files (*.xl*),*.xl*", 1, "Open DA Excel File") If FileOpenNameDA <> False then workbooks.open FileOpenNameDA
Good luck.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks