Auto Update Properties

  • Thread starter Thread starter kraljb
  • Start date Start date
K

kraljb

Is there a way to automatically update the properties of a spreadshee
when saved? (preferably without using VBA). Such that currently ther
are a series of spreadsheets that I deal with that everytime I save
change on, I have to go into the properties and change the versio
information.

Such that if a changeis made the version will auto-increment everytim
it is saved.

(This is on the Custom portion of the properties).

Thanks,
Joh
 
Hi
not possible without VBA. And AFAIK you can't even change them through
VBA
 
With VBA:

Maybe you could keep track of the version in a worksheet cell (???).

Then update it in the Before_Save event

Option Explicit
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)

Dim myCDP As DocumentProperties

Set myCDP = Me.CustomDocumentProperties

On Error Resume Next
myCDP("myVersion").Delete
On Error GoTo 0

myCDP.Add _
Name:="MyVersion", _
Type:=msoPropertyTypeString, _
Value:=Me.Worksheets("sheet1").Range("a1").Value, _
LinkSource:=False, _
LinkToContent:=False

End Sub

Or even retrieve it and add one????
 

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

Back
Top