Reply
 
Thread Tools Display Modes
  #1   Report Post  
Tom_Illingworth
 
Posts: n/a
Default Can I show the docproperties of a document next to it's hyperlink.

I have created a kind of index document that has hyperlinks to a whole bunch
of other documents spread around the server to make them easier to find. I
want to put a field next to each hyperlink that will show the 'docproperties
lastsavedtime' for the file that the link relates to. Is it possible or does
docproperties only display the info for the current document?
  #2   Report Post  
Jezebel
 
Posts: n/a
Default

Yes, DocProperties applies only to the current document. You'd need a macro
to do what you describe.



"Tom_Illingworth" wrote in
message ...
I have created a kind of index document that has hyperlinks to a whole
bunch
of other documents spread around the server to make them easier to find.
I
want to put a field next to each hyperlink that will show the
'docproperties
lastsavedtime' for the file that the link relates to. Is it possible or
does
docproperties only display the info for the current document?



  #3   Report Post  
Tom_Illingworth
 
Posts: n/a
Default

I'm scared of Macro's - any pointers on how to write a macro that would
achieve what i'm after?

Thanks

"Jezebel" wrote:

Yes, DocProperties applies only to the current document. You'd need a macro
to do what you describe.



"Tom_Illingworth" wrote in
message ...
I have created a kind of index document that has hyperlinks to a whole
bunch
of other documents spread around the server to make them easier to find.
I
want to put a field next to each hyperlink that will show the
'docproperties
lastsavedtime' for the file that the link relates to. Is it possible or
does
docproperties only display the info for the current document?




  #4   Report Post  
Jezebel
 
Posts: n/a
Default

Retrieving the properties from another document is easy enough. The
challenges here are

a) what triggers the macro - how often do you want to refresh the properties
from the source documents?
b) which properties do you want? - there are dozens of built-ins, and for
any given document the set of custom properties is open-ended
c) what do you want to do with the retrieved values?


To give you a taste of it, paste this into a code module and run it


Public Sub XYZ()

Dim pProp As Office.DocumentProperty
Dim pDoc As Word.Document

Set pDoc = Documents.Open("C:\.....doc") ----- add a
real file name here

On Error Resume Next
For Each pProp In pDoc.BuiltInDocumentProperties
Debug.Print pProp.Name, pProp.Value
Next
For Each pProp In pDoc.CustomDocumentProperties
Debug.Print pProp.Name, pProp.Value
Next

End Sub



"Tom_Illingworth" wrote in
message news
I'm scared of Macro's - any pointers on how to write a macro that would
achieve what i'm after?

Thanks

"Jezebel" wrote:

Yes, DocProperties applies only to the current document. You'd need a
macro
to do what you describe.



"Tom_Illingworth" wrote in
message ...
I have created a kind of index document that has hyperlinks to a whole
bunch
of other documents spread around the server to make them easier to
find.
I
want to put a field next to each hyperlink that will show the
'docproperties
lastsavedtime' for the file that the link relates to. Is it possible
or
does
docproperties only display the info for the current document?






  #5   Report Post  
Tom_Illingworth
 
Posts: n/a
Default


Thanks for that - i've been trying to give myself a crash course in macros
but I wasn't anywhere near what you've got! What I am wanting to do is have
a list of hyperlinks in an index something like this:


Link to Document 1 last updated: [savedate for document 1 dd/mm/yy]
Link to Document 2 last updated: [savedate for document 2 dd/mm/yy]
etc.

I would then need the macro to refresh the last saved fields for all the
documents each time the index file was opened.

Is this possible?



"Jezebel" wrote:

Retrieving the properties from another document is easy enough. The
challenges here are

a) what triggers the macro - how often do you want to refresh the properties
from the source documents?
b) which properties do you want? - there are dozens of built-ins, and for
any given document the set of custom properties is open-ended
c) what do you want to do with the retrieved values?


To give you a taste of it, paste this into a code module and run it


Public Sub XYZ()

Dim pProp As Office.DocumentProperty
Dim pDoc As Word.Document

Set pDoc = Documents.Open("C:\.....doc") ----- add a
real file name here

On Error Resume Next
For Each pProp In pDoc.BuiltInDocumentProperties
Debug.Print pProp.Name, pProp.Value
Next
For Each pProp In pDoc.CustomDocumentProperties
Debug.Print pProp.Name, pProp.Value
Next

End Sub



"Tom_Illingworth" wrote in
message news
I'm scared of Macro's - any pointers on how to write a macro that would
achieve what i'm after?

Thanks

"Jezebel" wrote:

Yes, DocProperties applies only to the current document. You'd need a
macro
to do what you describe.



"Tom_Illingworth" wrote in
message ...
I have created a kind of index document that has hyperlinks to a whole
bunch
of other documents spread around the server to make them easier to
find.
I
want to put a field next to each hyperlink that will show the
'docproperties
lastsavedtime' for the file that the link relates to. Is it possible
or
does
docproperties only display the info for the current document?








  #6   Report Post  
Jezebel
 
Posts: n/a
Default

Yes it's possible. If you write a macro called AutoOpen and attach it to the
document, it will run each time the document is opened. But you're throwing
yourself in the deep end if you don't know much about coding macros. Do you
really want to invest the time learning to swim in this pond?

If all the linked files are in the same folder, you can display the folder
in Windows Explorer set to details view -- that will show you the date last
saved. Mightn't be as elegant or convenient as you'd, but there's zero
effort in doing it, and zero maintenance ...



"Tom_Illingworth" wrote in
message ...

Thanks for that - i've been trying to give myself a crash course in macros
but I wasn't anywhere near what you've got! What I am wanting to do is
have
a list of hyperlinks in an index something like this:


Link to Document 1 last updated: [savedate for document 1
dd/mm/yy]
Link to Document 2 last updated: [savedate for document 2
dd/mm/yy]
etc.

I would then need the macro to refresh the last saved fields for all the
documents each time the index file was opened.

Is this possible?



"Jezebel" wrote:

Retrieving the properties from another document is easy enough. The
challenges here are

a) what triggers the macro - how often do you want to refresh the
properties
from the source documents?
b) which properties do you want? - there are dozens of built-ins, and for
any given document the set of custom properties is open-ended
c) what do you want to do with the retrieved values?


To give you a taste of it, paste this into a code module and run it


Public Sub XYZ()

Dim pProp As Office.DocumentProperty
Dim pDoc As Word.Document

Set pDoc = Documents.Open("C:\.....doc") ----- add a
real file name here

On Error Resume Next
For Each pProp In pDoc.BuiltInDocumentProperties
Debug.Print pProp.Name, pProp.Value
Next
For Each pProp In pDoc.CustomDocumentProperties
Debug.Print pProp.Name, pProp.Value
Next

End Sub



"Tom_Illingworth" wrote in
message news
I'm scared of Macro's - any pointers on how to write a macro that would
achieve what i'm after?

Thanks

"Jezebel" wrote:

Yes, DocProperties applies only to the current document. You'd need a
macro
to do what you describe.



"Tom_Illingworth" wrote in
message ...
I have created a kind of index document that has hyperlinks to a
whole
bunch
of other documents spread around the server to make them easier to
find.
I
want to put a field next to each hyperlink that will show the
'docproperties
lastsavedtime' for the file that the link relates to. Is it
possible
or
does
docproperties only display the info for the current document?








Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Inserting the same hyperlink on all pages in a document Shell Microsoft Word Help 1 February 3rd 05 09:44 AM
insert document as attachement after inserting email hyperlink swarm62 Microsoft Word Help 1 January 3rd 05 03:11 PM
document closes when I click on hyperlink to another document Larry Microsoft Word Help 1 December 17th 04 04:31 PM
Inserting a hyperlink - Place in this document rhewell Microsoft Word Help 3 December 14th 04 03:49 AM
Hyperlink in a word document JR Microsoft Word Help 2 December 9th 04 08:37 PM


All times are GMT +1. The time now is 05:16 AM.

Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"