View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Gord Dibben Gord Dibben is offline
external usenet poster
 
Posts: 22,906
Default How to click a cell with mouse and have a different tab appear

Doubleclick event code could work.

Private Sub Worksheet_BeforeDoubleClick( _
ByVal Target As Excel.Range, Cancel As Boolean)
'Substitute your cells/sheetnames
Select Case Target.Address(False, False)
Case "A1"
Sheets(Target.Value).Select
Case "A2"
Sheets(Target.Value).Select
Case "A3"
Sheets(Target.Value).Select
End Select
Cancel = True
End Sub

This is sheet event code. Right-click on the sheet tab and "View Code".

Copy/paste into that sheet module.


Gord Dibben MS Excel MVP

On Thu, 19 Jun 2008 13:26:02 -0700, Randy Carriere <Randy
wrote:

I was wondering if there is a way where I can click say cell A1 which
currently has the text 'Tuesday' in it. By clicking on this cell, the user
is directed to a new tab (which the user has labelled as Tuesday).

My knowledge is somewhat limited. I know I can run a macro and then press
<CTRL and the short cut key, but I was hoping to be able to just use the
mouse and click on the cell to direct me to the new tab.

Any suggestions would be greatly appreciated.