Can I show a formula's result on a worksheet tab?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Can anyone help? I would like to be able to see a result by just glancing at
the tabs in a workbook - perhaps lazy by not reviewing a summary page but
quicker to ingest!
 
You don't give much to go on, but here's one way:

Assume you want to see the sum of Sheet1, cell A1 and Sheet4, cell J10
in the tab of Sheet4. Put this in the ThisWorkbook code module:

Private Sub Workbook_SheetCalculate(ByVal Sh As Object)
Dim dTemp As Double
With Sheet4
On Error Resume Next
dTemp = Sheet1.Range("A1").Value + .Range("J10").Value
.Name = CStr(dTemp)
If Not .Name = dTemp Then .Name = "~~~ERROR!~~~"
On Error GoTo 0
End With
End Sub

If you're not familiar with macros, see

http://www.mvps.org/dmcritchie/excel/getstarted.htm

Note that you need to use the Sheets' code names (as shown in the
Project Explorer) if you're changing the tab names of the sheets of
interest.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top