Greetings-
I am attempting to export selected sheets of a master workbook to either 1, 2, or 3 new workbooks, depending on the value of cell C27 (which will be 1, 2, or 3). The filename of each new workbook will also vary depending on C27’s value. I’m a near-total novice at VBA, but this is what I’ve come up with. When I run the code, I get the “else without if” error. I’ve tried many different variations of If, Else, and
ElseIf… so the error is probably occurring because I am going about this task in a fundamentally wrong way. I cannot upload the workbook in question due to the security restrictions at my workplace. I am sure there are much better ways to do what I am attempting, but I am at the limit of my knowledge of VBA. Any assistance in fixing the code would be greatly appreciated.
![]()
Please Login or Register to view this content.
Bookmarks