Linked Pictures, etc.

Q

Q. John Chen

I have a Publish 2003 newsletter document . There are linked pictures
that are changed every day.

When I mannually open the document, the picture is not changed
automatically, go to graphic manager, it indicate the "Original is
modified" and have to "Update this link" manaully.

Questions:

1. Is there a setting that I can set so the linked picture is alway
updated by itself when it open.

2. if not, how can I do this programmtically. I can write a macro find
a the shapes of type linkedPicture but don't know what method to
update the link.

3. This question is beyond linked picture. Is there a way to use the
object model from other development tools such as .NET/C#. So I don't
even have to open the Publisher. I have do similar for Excel so though
it should be.


Thanks

John
 
Q

Q. John Chen

I have a Publish 2003 newsletter document . There are linked pictures
that are changed every day.

When I mannually open the document, the picture is not changed
automatically, go to graphic manager, it indicate the "Original is
modified" and have to "Update this link" manaully.

Questions:

1. Is there a setting that I can set so the linked picture is alway
updated by itself when it open.

2. if not, how can I do this programmtically. I can write a macro find
a the shapes of type linkedPicture but don't know what method to
update the link.

3. This question is beyond linked picture. Is there a way to use the
object model from other development tools such as .NET/C#. So I don't
even have to open the Publisher. I have do similar for Excel so though
it should be.

Thanks

John

I figured that out with Macro.
Dim pbPage As Page
Dim pbShape As Shape

For Each pbPage In ActiveDocument.Pages
For Each pbShape In pbPage.Shapes
If pbShape.Type = pbLinkedPicture And
pbShape.PictureFormat.IsLinked = True Then ' Note: only shape.Type
cause problem.
If pbShape.PictureFormat.LinkedFileStatus =
pbLinkedFileModified Then
pbShape.PictureFormat.Replace
(pbShape.PictureFormat.Filename)
End If
End If
Next pbShape
Next pbPage

I can also do this in .NET with Interop.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top