I export data from Oracle and each time I export the export file name and tab is named something different. So I can't write a macro to select a tab to rename it when the tab name is different each time a new export is done from Oracle. What I want is to write a VBA code to rename the worksheet's or tab's name to "OR" without quotation marks.
or another option would be;
Since I wasn't able to rename the tab using VBA because it would require knowing the name of the file, so instead I modified my macro to create a new worksheet called sheet1 and attempted to copy the data from the other tab using the previous tab command/function (unsure what the correct terminology to use here). Unfortunately, it failed to go to the previous tab because I can't click the tab using create macro because it would write a vba script with the exact name of the oracle created tab that changes each time. So is there a VBA script that switches between tabs without having to click it and without knowing the name of the worksheet or tab?
Answer both if you don't mind.
Bookmarks