Solved

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

Posted on 2002-06-29
12
518 Views
Last Modified: 2012-08-14
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,
0
Comment
Question by:linschoten
  • 7
  • 5
12 Comments
 
LVL 44

Expert Comment

by:bruintje
ID: 7119638
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
 
LVL 3

Author Comment

by:linschoten
ID: 7119704
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
 
LVL 44

Expert Comment

by:bruintje
ID: 7119723
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
Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 3

Author Comment

by:linschoten
ID: 7119729
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
 
LVL 44

Expert Comment

by:bruintje
ID: 7119744
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
 
LVL 44

Expert Comment

by:bruintje
ID: 7119759
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
 
LVL 44

Expert Comment

by:bruintje
ID: 7119760
oops change the

word.application.10

to

word.application
or
word.application.8
0
 
LVL 3

Author Comment

by:linschoten
ID: 7120495
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
 
LVL 3

Author Comment

by:linschoten
ID: 7120496
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
 
LVL 44

Accepted Solution

by:
bruintje earned 200 total points
ID: 7120551
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
 
LVL 3

Author Comment

by:linschoten
ID: 7120612
thanks heaps for this
0
 
LVL 44

Expert Comment

by:bruintje
ID: 7120620
glad i could help, and thanks for the grade
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Some time ago I was asked to create a VBA function that would calculate a check digit for an input number, using the following procedure: First, sum up all the individual digits in the number If that sum value has more than one digit, then sum up …
My experience with Windows 10 over a one year period and suggestions for smooth operation
The viewer will learn how to simulate a series of coin tosses with the rand() function and learn how to make these “tosses” depend on a predetermined probability. Flipping Coins in Excel: Enter =RAND() into cell A2: Recalculate the random variable…
The viewer will learn how to create a normally distributed random variable in Excel, use a normal distribution to simulate the return on an investment over a period of years, Create a Monte Carlo simulation using a normal random variable, and calcul…

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question