Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hello!
Thanks for at least looking at my request.... I have a workbook and I have recorded a macro to copy a sheet to a new workbook and then paste the values to get rid of all the formulae. I then want to return to the original workbook to make further changes with the same macro. Problem is, the original worksheet may not have been saved under a common name. It there a way with VBA to reselect the original sheet regardless of its name? Everything works fine with a known workbook name specified in the macro. Many thanks, ------------------------------------------------ ~~ Message posted from http://www.ExcelTip.com/ ~~ View and post usenet messages directly from http://www.ExcelForum.com/ |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Dim wSht as WorkSheet
Dim wBk as WorkBook Set wSht = ActiveSheet Set wBk = ActiveWorkbook ' Your sheet copy code. wBk.Activate wSht.Activate HTH Paul --------------------------------------------------------------------------------- Hello! Thanks for at least looking at my request.... I have a workbook and I have recorded a macro to copy a sheet to a new workbook and then paste the values to get rid of all the formulae. I then want to return to the original workbook to make further changes with the same macro. Problem is, the original worksheet may not have been saved under a common name. It there a way with VBA to reselect the original sheet regardless of its name? Everything works fine with a known workbook name specified in the macro. Many thanks, |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
copying workbook formating to a differnent workbook | Excel Worksheet Functions | |||
Copying Formulas from Workbook to Workbook | Excel Discussion (Misc queries) | |||
How do I hide and unhide the same columns without reselecting | Excel Worksheet Functions | |||
Copying A Worksheet From Each Open Workbook to an new Workbook | Excel Worksheet Functions | |||
Copying charts from workbook to workbook | Charts and Charting in Excel |