RAJESH1960
Banned for repeated rules violations
- Joined
- Mar 26, 2020
- Messages
- 2,313
- Office Version
- 2019
- Platform
- Windows
Hello experts,
This is an image of a sample workbook with 5 different sheet names. There are a minimum 4 sheets in any workbook which may have up to 8 or more sheets in different scenarios. With the help of my code, I append all the sheets in the workbook except Z and X . I need your expertise to help me with a code to add it in the beginning of the code. When I run the code, before the code appends the sheets, I want the message box to display, " Are you sure you want to append sheets A, B and C." with a Yes No option in the message box. The code should read all the names of the sheets in the workbook except Z and X. If there are only two sheets other than Z and X then the msg. box should display a message box stating those sheets names and similarly if there are 4 or more sheets other than Z and X then it should display message box with all the four names of the sheets.
In short, when I run the code, the code should display the message, the code is going to append sheets except Z and X.
Thank you in advance.
This is an image of a sample workbook with 5 different sheet names. There are a minimum 4 sheets in any workbook which may have up to 8 or more sheets in different scenarios. With the help of my code, I append all the sheets in the workbook except Z and X . I need your expertise to help me with a code to add it in the beginning of the code. When I run the code, before the code appends the sheets, I want the message box to display, " Are you sure you want to append sheets A, B and C." with a Yes No option in the message box. The code should read all the names of the sheets in the workbook except Z and X. If there are only two sheets other than Z and X then the msg. box should display a message box stating those sheets names and similarly if there are 4 or more sheets other than Z and X then it should display message box with all the four names of the sheets.
In short, when I run the code, the code should display the message, the code is going to append sheets except Z and X.
Thank you in advance.