hi,ive this code from somewhere in this forum.
this code is working great but i want the number in 6 digits.
example if the sheetname is 5.then in the cell i want it as 000005.
if 700 then 000700
can someone help?thanks a lot
Code:
Function WhoAmI() As String
Dim wb As Workbook
Dim ws As Worksheet
Set wb = ActiveWorkbook
Set ws = wb.ActiveSheet
Application.Volatile
WhoAmI = ws.Name
Set wb = Nothing
Set ws = Nothing
End Function
use =WhoAmI()
this code is working great but i want the number in 6 digits.
example if the sheetname is 5.then in the cell i want it as 000005.
if 700 then 000700
can someone help?thanks a lot
Last edited: