How do I insert an existing worksheet (previously exported from the same workbook)? I need to be able to do it programmatically.
Thank you!!
How do I insert an existing worksheet (previously exported from the same workbook)? I need to be able to do it programmatically.
Thank you!!
Hi,
You may have to provide more info, are you trying to insert a worksheet into another workbook?
I need to insert an existing worksheet into the workbook. The worksheet was previously exported (ActiveWorkbook.SaveAs) from the workbook. I need to reinsert it into the same workbook it was exported from.
![]()
Please Login or Register to view this content.
Entia non sunt multiplicanda sine necessitate
Thanks for the help. I tried it but I get an error: Run-time error '1004': Method 'Add' of object 'Sheets' failed. Any idea?
Did you change the path and filename as appropriate?
I'm pretty sure. I've looked at through debugger. I even tried to use a hard coded path instead but no luck.
Hmm. Try
![]()
Please Login or Register to view this content.
Exactly the same error!!!
I'm obviously doing something wrong but what?
Got it. It's:
Sheets.Add Type:="C:\somePath\the file I saved earlier"
Weird. Thank you!
Good job, glad you got it sorted.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks