Re: Macro Based hyperlink for Contents page
- From: zakfalls <zakfalls@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Tue, 15 Apr 2008 11:11:00 -0700
Hi David,
thats brilliant, thanks, just tried changing the security settings without
having the file open, and it works.
thanks for your help, much appreciated.
"David M. Marcovitz" wrote:
If everyone is in the 2003 version, you might want to ask your questions.
in the Windows PowerPoint group (microsoft.public.powerpoint) as you
have landed in the Mac group. Did you change security settings while the
file was open? Macro security is read when the file is opened. If you
change security while the file is open, it will have no effect until you
close and re-open the file.
--David
--
David M. Marcovitz
Microsoft PowerPoint MVP
Author of _Powerful PowerPoint for Educators_
http://www.PowerfulPowerPoint.com/
=?Utf-8?B?emFrZmFsbHM=?= <zakfalls@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in
news:45A36E0A-8949-4C68-A45B-E1BFDB0ECB8B@xxxxxxxxxxxxx:
Hi,
Everyone is using 2003 version, i initially thought it might be a
security problem, but i have changed the settings on their computer
and set it at low!!!.
Thanks
"David M. Marcovitz" wrote:
What version of PowerPoint are you using and what version is the
other person using? Does the other person have macro security set so
the macro can run?
--David
--
David M. Marcovitz
Microsoft PowerPoint MVP
Author of _Powerful PowerPoint for Educators_
http://www.PowerfulPowerPoint.com/
=?Utf-8?B?emFrZmFsbHM=?= <zakfalls@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote
in news:19C4AE21-DDE3-442B-8889-8102B9DBD66A@xxxxxxxxxxxxx:
Hi,
i have ben trying to set-up a contents page which will update
automatiaclly whenever a slide is added or removed.
the only i have found of doing this is using a macro linked to the
hyperlinks (unfortunately, i can't find the the post where i got
this answer from).
it works when you have slide number in the following format <xx> as
a hyperlink to the relavent slide and the macro updates the new
position of the slide when a slide is removed or added. the macro
coding is as follows:
Sub contents ()
Dim ohl As Hyperlink
Dim newtxt As TextRange
Dim Ipos1 As Integer
Dim Ipos2 As Integer
Dim InewID As Integer
Dim InewIndex As Integer
For Each osld In ActivePresentation.Slides
For Each ohl In osld.Hyperlinks
If TypeName(ohl.Parent.Parent) = "TextRange" Then
InewID = Left$(ohl.SubAddress, 3)
InewIndex =
ActivePresentation.Slides.FindBySlideID(CInt(InewID)).SlideIndex
Ipos1 = InStr(1, ohl.TextToDisplay, "<") Ipos2 = InStr(1,
ohl.TextToDisplay, ">") If Ipos1 <> 0 And Ipos2 <> 0 Then
ohl.TextToDisplay = Left$(ohl.TextToDisplay, Ipos1 - 1) & _
"<" & CStr(InewIndex) & ">" & Right$ _
(ohl.TextToDisplay, Len(ohl.TextToDisplay) - Ipos2)
End If
End If
Next ohl
Next osld
Exit Sub
errhandler:
MsgBox "**ERROR**" & vbCrLf & "Error is " & Err.Description
End Sub
this works perfectly, however, if i send the presentation to
someone else with the same software, they are able to see the
macro, but cannot click on the "Run" button in Macro tool bar.
any ideas as to why this is happening and is there any way around
it?
Thanks
- References:
- Macro Based hyperlink for Contents page
- From: zakfalls
- Re: Macro Based hyperlink for Contents page
- From: David M. Marcovitz
- Re: Macro Based hyperlink for Contents page
- From: zakfalls
- Re: Macro Based hyperlink for Contents page
- From: David M. Marcovitz
- Macro Based hyperlink for Contents page
- Prev by Date: Re: Macro Based hyperlink for Contents page
- Next by Date: Re: Presenter tools & "Slide Show" ALWAYS starts at slide 1 :'-(
- Previous by thread: Re: Macro Based hyperlink for Contents page
- Next by thread: Re: Triggers
- Index(es):