file owner properties

  • Thread starter Thread starter Funtime
  • Start date Start date
F

Funtime

I know xcacls.vbs can be used to change file permissions. Is there a similar
tool to change file ownership?
 
If you just want to change the name of the owner and such, go to File then
Properties.
 
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.
 
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
 

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

Similar Threads


Back
Top