![]() |
Returning to active sheet
Hi,
I have a series of worksheets which store data on a separate sheet "Results". Data from (e.g.) Sheet A is moved to A1 in Results, then a small macro checks to see if cell contains data and if not moves down to the next empty cell. When it finds the empty cell it pastes the data. How do I then move back to Sheet A? I can't use the actual name because the user may have been on Sheet B, C etc. Any help gratefully received! |
Returning to active sheet
If you are writing the code, you should know the name of sheet A. You would
use the sheet name to return to it. Maybe if you post the code you are using, a better solution could be offered. "David" wrote in message ... Hi, I have a series of worksheets which store data on a separate sheet "Results". Data from (e.g.) Sheet A is moved to A1 in Results, then a small macro checks to see if cell contains data and if not moves down to the next empty cell. When it finds the empty cell it pastes the data. How do I then move back to Sheet A? I can't use the actual name because the user may have been on Sheet B, C etc. Any help gratefully received! |
Returning to active sheet
Sorry, perhaps I wasn't clear enough - I used Sheet A as an example as the
user could be coming from any one of a number of sheets and I need to return to whichever sheet the user was on - hence sheet name cannot be used. "JLGWhiz" wrote in message ... If you are writing the code, you should know the name of sheet A. You would use the sheet name to return to it. Maybe if you post the code you are using, a better solution could be offered. "David" wrote in message ... Hi, I have a series of worksheets which store data on a separate sheet "Results". Data from (e.g.) Sheet A is moved to A1 in Results, then a small macro checks to see if cell contains data and if not moves down to the next empty cell. When it finds the empty cell it pastes the data. How do I then move back to Sheet A? I can't use the actual name because the user may have been on Sheet B, C etc. Any help gratefully received! |
Returning to active sheet
Fixed it - I used the worksheets index number to return to Sheet 1, and made
sure that was the only sheet visible. Thanks JLGWhiz for your quick reply, by the way. "David" wrote in message ... Sorry, perhaps I wasn't clear enough - I used Sheet A as an example as the user could be coming from any one of a number of sheets and I need to return to whichever sheet the user was on - hence sheet name cannot be used. "JLGWhiz" wrote in message ... If you are writing the code, you should know the name of sheet A. You would use the sheet name to return to it. Maybe if you post the code you are using, a better solution could be offered. "David" wrote in message ... Hi, I have a series of worksheets which store data on a separate sheet "Results". Data from (e.g.) Sheet A is moved to A1 in Results, then a small macro checks to see if cell contains data and if not moves down to the next empty cell. When it finds the empty cell it pastes the data. How do I then move back to Sheet A? I can't use the actual name because the user may have been on Sheet B, C etc. Any help gratefully received! |
All times are GMT +1. The time now is 12:05 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com