Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Hyperlinks in charts? 1

Status
Not open for further replies.

JensKKK

Technical User
May 8, 2007
119
GB
Hyperlinks in charts.

Is there an (easy) way to get a hyperlink into a chart. I wonder if I could put it in the title or in the figure legend.

Easy question lets see if any answers are rolling in onthat one.

Thanks
 
AFAIK, there is no way to do this

Rgds, Geoff

We could learn a lot from crayons. Some are sharp, some are pretty and some are dull. Some have weird names and all are different colours but they all live in the same box.

Please read FAQ222-2244 before you ask a question
 
I guess you could assign a macro to the chart click event and then test the mouse position co-ords to see if it was in the right area and then do what you need to do but doesn't really fall into the remit of "easy"

Rgds, Geoff

We could learn a lot from crayons. Some are sharp, some are pretty and some are dull. Some have weird names and all are different colours but they all live in the same box.

Please read FAQ222-2244 before you ask a question
 
That is an idea.

I actually have done something similar before. Its a real shame that I copy the graph with the copypicuture command and embed it in a report.

Apparently it is possible to create a macro on Picture1_Click.

Thanks again. That was a brilliant idea.
 
Anyway, you can add a shape with no border lines and transparent interior. When you add a hyperlink to it, it will act as a hot spot on the chart.

combo
 
ooooh - yeh - that as well !!

that's why I always prefix things like this with AFAIK because every single time I say that something cannot be done, I get proved wrong. I should learn really ;-)

Rgds, Geoff

We could learn a lot from crayons. Some are sharp, some are pretty and some are dull. Some have weird names and all are different colours but they all live in the same box.

Please read FAQ222-2244 before you ask a question
 
It is rather a cheat - chart items can't have hyperlinks.

combo
 
Anyway, you can add a shape with no border lines and transparent interior. When you add a hyperlink to it, it will act as a hot spot on the chart.

combo

Sounds like a plan but I no idea what you are talking about. Could please point me in the right direction. I am still a beginner in VBA.

Thanks
 
no real need for vba unless you need to automate the creation of chart and hyperlink

Simply add a new rectangle from the shapes collection and right click to add a hyperlink. then, drag it over the chart to where you want it to be and set its border colour to none and interior colour to none. It will look like it isn;t there but if you click on it, the hyperlink will be activated...

Rgds, Geoff

We could learn a lot from crayons. Some are sharp, some are pretty and some are dull. Some have weird names and all are different colours but they all live in the same box.

Please read FAQ222-2244 before you ask a question
 
There is no vba here - add any shape onto the chart (or worksheet) and right-click it. From the popup menu you can both add a hyperlink and format the shape (remove border and filling).

combo
 
And you can choose any of the two above methods...

combo
 
Any idea where the shaps collection is in MS Excel 2002?

Which pull down menu? For example.

Thanks
 
View>Toolbars>Drawing

Rgds, Geoff

We could learn a lot from crayons. Some are sharp, some are pretty and some are dull. Some have weird names and all are different colours but they all live in the same box.

Please read FAQ222-2244 before you ask a question
 



If you are using a Chart Object, as opposed to a ChartObject Object, you can easily use the GetChartElement Method in the Chart_MouseDown event.

If you are using a ChartObject Object, you must create a class module for your Chart in the ChartObject in order to expose the events for that ChartObject's Chart Object.

Using the GetChartElement Method, you can, for instance, click on a series point and know which series and which point in that series was selected.

Skip,

[glasses] To be safe on the [red]FOURTH[/red],
Don't take a [red]FIFTH[/red] on the [red]THIRD[/red]
Or you might not come [red]FORTH[/red] on the [red]FIFTH[/red]
[red][highlight blue]FORTH[/highlight][/red][white][highlight red]WITH[/highlight][/white] [tongue]
 
Skip I understand only half (even that is a exagerated) of what you are saying, but don't worry I am happy with the solution i have got.


Thanks again.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top