Hyperlink coordinate

  • Thread starter Thread starter Adam
  • Start date Start date
A

Adam

Well, I've looked around and have seen a couple similar things but not
quite the same.

I have Office 2003 and I'm using C# to convert all the slides of a
PowerPoint presentation into GIFs and generate custom html files for
displaying on the web. So far I've gotten everything working great but
I'd also like to generate image maps of the hyperlinks to the pages
too.

I can get the hyperlinks like this:

Slide slide = ppt.Slides[curSlide];
for(int i=1; i<=slide.Hyperlinks.Count; i++)
MessageBox.Show(slide.Hyperlinks.Address);

But I can't figure out which shape the hyperlink goes with. Every time
I find a hyperlink using the above code I always get nulls using the
code below:

for(int i=1; i<=slide.Shapes.Count; i++)
{
Shape shape = slide.Shapes;
ActionSetting action;
action = shape.ActionSettings[PpMouseActivation.ppMouseClick];
MessageBox.Show(action.Hyperlink.Address);
}

Does anyone know why?
 
Adam,
This isn't any quick way to arrive at this information. You will need to
iterate thru the shape and also parse the text information to arrive at the
hyperlink association.
Also, you need to check the SubAddress property for local hyperlinks
(slide).

Regards
Shyam Pillai

http://www.mvps.org/skp
 
[CRITICAL UPDATE - Anyone using Office 2003 should install the critical
update as soon as possible. From PowerPoint, choose "Help -> Check for
Updates".]
[TOP ISSUE - Are you having difficulty opening presentations in PPT 2003
that you just created in PPT 2003? -
http://support.microsoft.com/?id=329820]

Hello Adam,

First of all, I guess that I'm curious as to why you are doing all of this
work instead of using the built-in capabilities of PowerPoint to create
HTML output. Perhaps there are a number of suggestions you might want to
submit regarding the HTML output from PowerPoint which, if implemented in
some future version of PowerPoint deliver the solution you are looking for
directly from within PowerPoint (without having to build a custom
solution).

Also, on a side note, If you use the publish options for saving as HTML
from PowerPoint to generate output compatible with older versions of IE
(version 3.0) PowerPoint generates additional HTML files which include the
image map coordinates you might be looking for. Look for resulting output
files following the naming convention of:

v3_slideNNNN.htm

where NNNN is the number of the slide and v3 indicates that this is the
HTML file which would be used if you were displaying this presentation on a
much earlier version of IE or Netscape Navigator.

Anyway, if you (or anyone else reading this message) have suggestions for
how the HTML output from PowerPoint might be changed for some future
version of PowerPoint, don't forget to send your feedback (in YOUR OWN
WORDS, please) to Microsoft at:

http://register.microsoft.com/mswish/suggestion.asp

It's VERY important that, for EACH wish, you describe in detail, WHY it is
important TO YOU that your product suggestion be implemented. A good wish
submssion includes WHAT scenario, work-flow, or end-result is blocked by
not having a specific feature, HOW MUCH time and effort ($$$) is spent
working around a specific limitation of the current product, etc. Remember
that Microsoft receives THOUSANDS of product suggestions every day and we
read each one but, in any given product development cycle, there are ONLY
sufficient resources to address the ones that are MOST IMPORTANT to our
customers so take the extra time to state your case as CLEARLY and
COMPLETELY as possible so that we can FEEL YOUR PAIN.

IMPORTANT: Each submission should be a single suggestion (not a list of
suggestions).

John Langhans
Microsoft Corporation
Supportability Program Manager
Microsoft Office PowerPoint for Windows
Microsoft Office Picture Manager for Windows

For FAQ's, highlights and top issues, visit the Microsoft PowerPoint
support center at: http://support.microsoft.com/default.aspx?pr=ppt
Search the Microsoft Knowledge Base at:
http://support.microsoft.com/default.aspx?pr=kbhowto

This posting is provided "AS IS" with no warranties, and confers no rights.
Use of any included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm
 
Back
Top