Hello; I'm not at all good with Excel Macros or VBA scripts so please forgive me if this is a simple question..
Here's what I need to do. I have a spread sheet that contains several worksheets and I need to place a page number formula in a cell on the page rather than printing it as a header or footer command. I'm sure that this is possible but I'm not sure what the Macro or VBA code would look like or even where to place it.
Thanks in advance for your help on this....Scott
Welcome to Ozgrid.
I do not think there is a simple method without resorting to VBA.
With VBA you could add a command button and write this behind it.
I added the name and number you could edit out the name if you don't need itVB:Private Sub CommandButton1_Click() Dim ws As Worksheet For Each ws In Worksheets ws.Range("a1").Value = ws.Name ' Enters Sheet Name in A1 ws.Range("a2").Value = ws.Index ' Enters Sheet index in A2 Next ws End Sub
Last edited by carlmack; June 15th, 2006 at 02:41.
There are currently 1 users browsing this thread. (0 members and 1 guests)