Naresh Patel
asked on
Scoring
Hi Expert,
Need help to create VBA Code.
Step 1 Clicking Explore Button on sheet LT which search for LT.Z Sheet in workbook.
Step 2 If there, then End
Step 3 If Not there than create one - name LT.Z i.e. create copy of sheet Sample rename it to LT.Z
See attached File
Thanks
Z-Score.xlsm
Capture.PNG
Need help to create VBA Code.
Step 1 Clicking Explore Button on sheet LT which search for LT.Z Sheet in workbook.
Step 2 If there, then End
Step 3 If Not there than create one - name LT.Z i.e. create copy of sheet Sample rename it to LT.Z
See attached File
Thanks
Z-Score.xlsm
Capture.PNG
ASKER
Sorry "ee"
ASKER
Not That way if sheet name TT then Search for TT.Z if not found than create copy of sheet sample & rename to TT.Z
Thanks
Thanks
TT.Z, LT.Z, just change the code to suit. Have a look at the spreadsheet attached and press the Explore button to see what it does
Sub Explore()
Dim s As Worksheet
For Each s In ThisWorkbook.Sheets
If s.Name = "TT.Z" Then Exit Sub
Next s
Worksheets("Sample").Copy ThisWorkbook.Sheets(Sheets.Count)
ActiveSheet.Name = "TT.Z"
End Sub
Copy-of-Z-Score-1.xlsm
ASKER
working at once but if change Sheet Name to ACC then it wont create ACC.Z
OK I think I got it, try this one instead
Copy-of-Z-Score-2.xlsm
Copy-of-Z-Score-2.xlsm
ASKER
Yes up to the mark one more thing, if you can hide the sheet after creating... will be most use full for me.. after this I ll close this question.
Thank You
Thank You
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Mr.terencino,
I am on way back to home as and when I reach my place I will accept your answer as I can not run this code in phone.this is very 1st step of my whole project if you wish to solve more on this pls be with me, As per my understanding who start from scratch will know my next question much better than other.i will post my next question link in this question,if you wish to solve most welcome,if don't want - No hard feeling.
Thank You
I am on way back to home as and when I reach my place I will accept your answer as I can not run this code in phone.this is very 1st step of my whole project if you wish to solve more on this pls be with me, As per my understanding who start from scratch will know my next question much better than other.i will post my next question link in this question,if you wish to solve most welcome,if don't want - No hard feeling.
Thank You
ASKER
Thank You Very Much
ASKER
Need one more thing if my sample sheet is hidden then code will perform same.
My next question link which next procedure for same file.
Scoring V 2
Thank You
My next question link which next procedure for same file.
Scoring V 2
Thank You
Open in new window
...Terry