Rolling out the "prompt for document properties" option within Off97sr2

How do I roll out the option "prompt for document properties" within MS Office97sr2.
I want to roll out via a Logon Script the option Tools - Options - Save "prompt for document properties".
I've had a look at differences in the registry using RegSnap, seeing if any files change, but nothing seems to pop up to indicate any file or registry change.
I don't want everyone to have to manually make the change but would like something enforced, like a registry hack that would automatically make the change. We have roaming profiles here so a registry hack would need to account for that.
Thanks,
LVL 3
linschotenAsked:
Who is Participating?
 
bruintjeConnect With a Mentor Commented:
funny couldn't find excel this morning but here it is

Set oShell = WScript.CreateObject("WScript.Shell")
Set oXL=WScript.CreateObject("Excel.Application")
With oXL
 .Visible=False
 .Workbooks.Add
 .Options.PromptForSummaryInfo=True
 .ActiveWorkbook.Close()
 .Quit()
end With
Set oXL=Nothing

and powerpoint is really the most fun of the 3 it's not doable through powerpoint itself BUT we got the registry !

Dim WSHShell, PromptProps, RegLoc
Set WSHShell = WScript.CreateObject("WScript.Shell")
RegLoc = "HKEY_CURRENT_USER\Software\Microsoft\Office\10.0\PowerPoint\Options"
PromptProps = RegLoc & "\PromptForFileProperties"
WSHShell.RegWrite PromptProps,"1"
WScript.Quit    

beware for powerpoint, you got to use the number in the key like i did for XP

HKEY_CURRENT_USER\Software\Microsoft\Office\10.0\PowerPoint\Options

so for 97 it would be

HKEY_CURRENT_USER\Software\Microsoft\Office\8.0\PowerPoint\Options

2K would be

HKEY_CURRENT_USER\Software\Microsoft\Office\9.0\PowerPoint\Options

you can try something in the script like

Dim WSHShell, PromptProps, RegLoc
Set WSHShell = WScript.CreateObject("WScript.Shell")
on error resume next
'for office 97
RegLoc = "HKEY_CURRENT_USER\Software\Microsoft\Office\8.0\PowerPoint\Options"
PromptProps = RegLoc & "\PromptForFileProperties"
WSHShell.RegWrite PromptProps,"1"
'for office 2000
RegLoc = "HKEY_CURRENT_USER\Software\Microsoft\Office\9.0\PowerPoint\Options"
PromptProps = RegLoc & "\PromptForFileProperties"
WSHShell.RegWrite PromptProps,"1"
WScript.Quit    

can't test this got them all three in my registry ;)

really weird all three got their own sequence, other tabs, registry yes/no or to set through code in the application or not

why have they solved it so incredible inconsistent? the only reason i could think of is hackers? or just simple product group rivalry?
0
 
bruintjeCommented:
Hi linschoten,

do you want to do this within the application or outside the application

i mean if you want to do this automatically then there's no need for a prompt to the user, you want a silent process making the changes to the document properties

am i correct or not?

HAGD:O)Bruintje
0
 
linschotenAuthor Commented:
Yes please, this is to run separately, we are wanting people to log onto to our NT Domain and when they do the Windows NT Logon Script will call either a .BAT file or .VBS file etc... I don't want any prompting this will be invisable to the user.
So the next time they want to save documents they will get the prompt for document properties. Of course we will let them know what to expect but that is sometime else to do.
Thanks,
0
Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

 
bruintjeCommented:
this is a bit of a mixed bag, since there's no common way of doing it across all applications in office

-for word and frontpage it is easy since you got the interface providing this functionality to prompt on save it canbe done through vbs

-for excel,access, powerpoint etc.... it is not easy since there's the dialog under the save button so you got to work with templates that contain a custom save dialog that will prompt the user

so for which applications do you need this functionality?
and are you able to work with custom templates since there could be some problems with templates and roaming profiles
0
 
linschotenAuthor Commented:
ok sorry for that, the request is for Word97sr2, this is running on Windows98. For the moment. I would have thought once the option is ticked it would apply to all templates.
Maybe I don't really know Word that well.
I Hope this is enough to answer your question.
0
 
bruintjeCommented:
in theory this vbs script should do it

Set oShell = WScript.CreateObject("WScript.Shell")
Set oWord=WScript.CreateObject("Word.Application.8")
With oWord
  .Visible=true
  .Documents.Add
  .Options.SavePropertiesPrompt=true
  .ActiveDocument.Close()
  .Quit()
end With
Set oWord=Nothing

but in my xp it simply doesn't work only from within the word vb editor it works with exactly the same code

so i'm still researching
0
 
bruintjeCommented:
Set oShell = WScript.CreateObject("WScript.Shell")
Set oWord=WScript.CreateObject("Word.Application.10")
With oWord
  .Visible=False
  .Documents.Add
  .Options.SavePropertiesPrompt=True
  .DefaultSaveFormat = ""
  .ActiveDocument.Close()
  .Quit()
end With
Set oWord=Nothing

this works for me, after a reboot and after the discovery that if you got word open when running this script it doesn't work
0
 
bruintjeCommented:
oops change the

word.application.10

to

word.application
or
word.application.8
0
 
linschotenAuthor Commented:
Thanks for that, it works on both Word97 and Word2000 with the word.application setting. Brillant.
Could you do the same for Excel and PowerPoint too please.

Excel-Tools-Options-General-Prompt for workbook properties

PowerPoint-Tools-Options-Save-Prompt for file properties

Thanks if you can do this.
Ta,
0
 
linschotenAuthor Commented:
Thanks for that, it works on both Word97 and Word2000 with the word.application setting. Brillant.
Could you do the same for Excel and PowerPoint too please.

Excel-Tools-Options-General-Prompt for workbook properties

PowerPoint-Tools-Options-Save-Prompt for file properties

Thanks if you can do this.
Ta,
0
 
linschotenAuthor Commented:
thanks heaps for this
0
 
bruintjeCommented:
glad i could help, and thanks for the grade
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.