Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
hyperlink macro
is there a way to have it when i click on cell A1 it will have a message box
of value in b1. if i click on a2, message box of b2...etc thanks in advance |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
hyperlink macro
Hi Choice,
Try: '============= Private Sub Worksheet_SelectionChange(ByVal Target As Range) Dim rng As Range Set rng = Me.Range("A1:A10") '<<==== CHANGE If Not Intersect(rng, Target) Is Nothing Then With Target MsgBox "The value of " & .Address(0, 0) _ & " = " & Target.Offset(0, 1).Value End With End If End Sub '<<============= This is worksheet event code and should be pasted into the worksheets's code module (not a standard module and not the workbook's ThisWorkbook module): Right-click the worksheet's tab Select 'View Code' from the menu and paste the code. Alt-F11 to return to Excel. --- Regards, Norman "choice" wrote in message ... is there a way to have it when i click on cell A1 it will have a message box of value in b1. if i click on a2, message box of b2...etc thanks in advance |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Macro in Hyperlink | Excel Discussion (Misc queries) | |||
run macro hyperlink | Excel Discussion (Misc queries) | |||
Can I get a hyperlink to run a macro? | Excel Programming | |||
Intra-workbook hyperlink: macro/function to return to hyperlink ce | Excel Discussion (Misc queries) | |||
Macro to Copy Hyperlink to another file as a HYPERLINK, not text... | Excel Programming |