WORKAROUND
To work around this problem, use either of the following methods.
Method 1: Use Pack and Go
PowerPoint 2002 has a feature called Pack and Go. When you want to run a presentation on another computer, the Pack and Go Wizard can put all the required files into one archive file or span multiple disks. You then unpack the file on the destination computer or network share and run the presentation.
When you use Pack and Go on your presentation, you can choose to include all linked files in the presentation. When you do that, the Pack and Go Wizard coverts the absolute paths of the picture links to relative ones. That is, instead of the path being "C:\My Documents\My Pictures\image001.jpg", the path becomes "image001.jpg".
Packing a Presentation and Associated Files
To use Pack and Go on a presentation to run on another computer, follow these steps:
- Open the presentation that you want to pack.
- On the File menu, click Pack and Go.
- Follow the instructions in the Pack and Go Wizard.
When prompted for which drive to copy to, click Select destination and browse to a temporary file location. This is where you pack your presentation and its associated files. Click Next. - Choose to include Linked Files. At this point, you can choose to embed TrueType fonts with your presentation. Click Next.
- Do not include the viewer. Click Next, and then click Finish.
You can then copy the packed file and the Pngsetup.exe program to any drive or network share that you choose.
Unpacking a Presentation
To view your presentation, you must go to the location you copied the pack file to and unpack it. To do this, follow these steps:
- In Microsoft Windows Explorer, navigate to the location of the packed presentation, and then double-click Pngsetup.
- Enter the location where you want to unpack the file to.
- Click OK.
The presentation and the linked pictures will be unpacked in the location you chose.
Using Macro Code to Set Relative Path
Microsoft provides programming examples for illustration only, without warranty either
expressed or implied, including, but not limited to, the implied warranties of
merchantability and/or fitness for a particular purpose. This article assumes
that you are familiar with the programming language being demonstrated and the
tools used to create and debug procedures. Microsoft support professionals can
help explain the functionality of a particular procedure, but they will not
modify these examples to provide added functionality or construct procedures to
meet your specific needs. If you have limited programming experience, you may
want to contact a Microsoft Certified Partner or the Microsoft fee-based
consulting line at (800) 936-5200. For more information about Microsoft Certified
Partners, please visit the following Microsoft Web site:
For more information about the support options that are available and about how to contact Microsoft, visit the following Microsoft Web site:
NOTE: The following macro examples work only in PowerPoint. Visual Basic for Applications macros are not supported by the Microsoft PowerPoint Viewer. For additional information, click the following article number to view the article in the Microsoft Knowledge Base:
You can also use a macro to convert the links from absolute to relative. This will allow PowerPoint to locate the pictures based on the presentation's current location, as long as the pictures are in this same location.
The following is a code sample, showing one way in which this could be automated. This code sample assumes that the presentation and the linked pictures are in the same folder location. If they are not in the same folder location, then running this code will break the link to the picture.
Sample Code
- On the Tools menu, point to Macro, and then click Security.
- Click Medium for the Security level. Click OK.
- On the Tools menu, point to Macro, and then click Visual Basic Editor.
- On the Insert menu, click Module.
- Type the following code in the module:
Sub RelPict()
Dim oSlide As Slide
Dim oShape As Shape
Dim lPos As Long
Dim strLink As String
'
' Loop through the presentation checking each shape
' on each slide to see if it is a linked picture.
'
For Each oSlide In ActivePresentation.Slides
For Each oShape In oSlide.Shapes
If oShape.Type = msoLinkedPicture Then
With oShape.LinkFormat
'
' Search from the right hand portion of the source
' filename and find the first backslash "\" character.
'
lPos = InStrRev(.SourceFullName, "\")
'
' Check to see if the link has already been modified.
'
If lPos <> Null Then
'
' Determine how long the filename is, by subtracting
' the position the "\" character was found at from
' the total length of the source file name.
'
lPos = Len(.SourceFullName) - lPos
'
' Extract the filename from the source file name, then
' assign the filename to the source file name, turning
' it into a relative path.
'
strLink = Right(.SourceFullName, lPos)
.SourceFullName = strLink
End If
End With
End If
Next oShape
Next oSlide
End Sub