Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 41
Default How to link several charts in the same worksheet?


Hi there!

I have to creat links for some charts on the bottom of my worksheet. Since
charts are not assigned to a cell, I've searched some forums but nothing
worked.
Can anyone help me?
I've got macros on my workbook to open the file on the same worksheet. No
macros on any worksheet individually.

Here're my 3 findings and the instructions i followed for the fist link. For
the other links I guess I just need to add more IF's or buttons:



============1============

Create a Hyperlink to cell A1 on the same sheet (you can change the text to
display to make it meaningful). Right click the sheet tab and choose View
Code. Paste this into the window on the right:

code:
--------------------------------------------------------------------------------

Private Sub Worksheet_FollowHyperlink(ByVal Target As Hyperlink)
If Right(Target.Name, 2) = "A1" Then
Sheets("Chart1").Activate
End If
End Sub

--------------------------------------------------------------------------------

Change the reference to Chart1 to suit. Press Alt+F11 to return to your
worksheet, and try it out.



============2============

code:
--------------------------------------------------------------------------------

Private Sub Worksheet_FollowHyperlink(ByVal Target As Hyperlink)
If Target.Name = "Sheet2!A1" Then
ActiveSheet.ChartObjects("Chart 1").Activate
End If
End Sub



============3============

It's probably easier to add a button off the control toolbox and edit its
code to the following (change Chart1 to whatever your chart sheet is called)

Private Sub CommandButton1_Click()
ActiveWorkbook.Sheets("Chart1").Select
End Sub



HOPE TO GET YOUR HELP

Bruno
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,344
Default How to link several charts in the same worksheet?

Hi,

Do you mean you want a link at the top of the sheet that links to a chart
further down? If so, why not like to a cell near or under the charts? In
that case you would have a couple of hyperlink near the top of the
spreadsheet each linked to a different cell near each chart. To make the
hyperlink just press Ctrl+K and pick Place in This Document, and from the
right hand side select the sheet and then enter the cell address in the Type
the cell reference. Edit the Text to Display so you know where the hyperlink
is going.

--
Thanks,
Shane Devenshire


"Bruno" wrote:


Hi there!

I have to creat links for some charts on the bottom of my worksheet. Since
charts are not assigned to a cell, I've searched some forums but nothing
worked.
Can anyone help me?
I've got macros on my workbook to open the file on the same worksheet. No
macros on any worksheet individually.

Here're my 3 findings and the instructions i followed for the fist link. For
the other links I guess I just need to add more IF's or buttons:



============1============

Create a Hyperlink to cell A1 on the same sheet (you can change the text to
display to make it meaningful). Right click the sheet tab and choose View
Code. Paste this into the window on the right:

code:
--------------------------------------------------------------------------------

Private Sub Worksheet_FollowHyperlink(ByVal Target As Hyperlink)
If Right(Target.Name, 2) = "A1" Then
Sheets("Chart1").Activate
End If
End Sub

--------------------------------------------------------------------------------

Change the reference to Chart1 to suit. Press Alt+F11 to return to your
worksheet, and try it out.



============2============

code:
--------------------------------------------------------------------------------

Private Sub Worksheet_FollowHyperlink(ByVal Target As Hyperlink)
If Target.Name = "Sheet2!A1" Then
ActiveSheet.ChartObjects("Chart 1").Activate
End If
End Sub



============3============

It's probably easier to add a button off the control toolbox and edit its
code to the following (change Chart1 to whatever your chart sheet is called)

Private Sub CommandButton1_Click()
ActiveWorkbook.Sheets("Chart1").Select
End Sub



HOPE TO GET YOUR HELP

Bruno

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 41
Default How to link several charts in the same worksheet?

That was my first idea when I created the document, but the entries on the
top of the spreadsheet keep pushing the links down, and the charts don't
follow them.

Can anyone help me with this code problem?


"ShaneDevenshire" wrote:

Hi,

Do you mean you want a link at the top of the sheet that links to a chart
further down? If so, why not like to a cell near or under the charts? In
that case you would have a couple of hyperlink near the top of the
spreadsheet each linked to a different cell near each chart. To make the
hyperlink just press Ctrl+K and pick Place in This Document, and from the
right hand side select the sheet and then enter the cell address in the Type
the cell reference. Edit the Text to Display so you know where the hyperlink
is going.

--
Thanks,
Shane Devenshire


"Bruno" wrote:


Hi there!

I have to creat links for some charts on the bottom of my worksheet. Since
charts are not assigned to a cell, I've searched some forums but nothing
worked.
Can anyone help me?
I've got macros on my workbook to open the file on the same worksheet. No
macros on any worksheet individually.

Here're my 3 findings and the instructions i followed for the fist link. For
the other links I guess I just need to add more IF's or buttons:



============1============

Create a Hyperlink to cell A1 on the same sheet (you can change the text to
display to make it meaningful). Right click the sheet tab and choose View
Code. Paste this into the window on the right:

code:
--------------------------------------------------------------------------------

Private Sub Worksheet_FollowHyperlink(ByVal Target As Hyperlink)
If Right(Target.Name, 2) = "A1" Then
Sheets("Chart1").Activate
End If
End Sub

--------------------------------------------------------------------------------

Change the reference to Chart1 to suit. Press Alt+F11 to return to your
worksheet, and try it out.



============2============

code:
--------------------------------------------------------------------------------

Private Sub Worksheet_FollowHyperlink(ByVal Target As Hyperlink)
If Target.Name = "Sheet2!A1" Then
ActiveSheet.ChartObjects("Chart 1").Activate
End If
End Sub



============3============

It's probably easier to add a button off the control toolbox and edit its
code to the following (change Chart1 to whatever your chart sheet is called)

Private Sub CommandButton1_Click()
ActiveWorkbook.Sheets("Chart1").Select
End Sub



HOPE TO GET YOUR HELP

Bruno

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Link To Charts Lorcan Dene Charts and Charting in Excel 8 August 5th 09 04:51 PM
link excel charts to web pages and update charts automatically Signguy Charts and Charting in Excel 1 April 22nd 08 08:29 PM
Paste link for charts Warrain Charts and Charting in Excel 6 November 11th 07 05:10 PM
link colors to descriptions in bar charts mac Charts and Charting in Excel 4 May 18th 07 08:16 AM
how to link two charts in excel anjolaoluwa Charts and Charting in Excel 1 January 24th 05 08:34 PM


All times are GMT +1. The time now is 10:06 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"