file owner properties

F

Funtime

I know xcacls.vbs can be used to change file permissions. Is there a similar
tool to change file ownership?
 
S

Sean Timmons

If you just want to change the name of the owner and such, go to File then
Properties.
 
F

Funtime

I guess I did not put enough detail into my question. Sean highlights
exactly what I am trying to do in a very simple manual command.
I am trying to write a vba script for excel that will search through various
directories on my server, and selectively change the "owner" property of
individual files and folders. My reference to xcacls is an analogy to my
situation. I use the same search programing today and execute the xcacls.vbs
command in a shell to manipulate the files permissions property. Xcacls does
not control the ownership.
 
P

Peter T

Not sure what you mean by "ownership", author perhaps. If so, install
dsoFile
http://support.microsoft.com/kb/224351/en-us

Sub test()
' Tools/refs DSO OLE Document Properties Reader
Dim sFile As String
Dim sAuthorOrig As String
Dim sAuthorNew As String

sAuthorNew = "Funtime"
Dim dso As DSOFile.OleDocumentProperties
Set dso = New DSOFile.OleDocumentProperties

' some loop here
sFile = "C:\temp\book1.xls"

dso_Open sfilename:=sFile
' sAuthorOrig = dso.SummaryProperties.Author
dso.SummaryProperties.Author = sAuthorNew
dso.Save
' end loop

dso.Close

End Sub

Regards,
Peter T
 
Top