Results 1 to 5 of 5
  1. #1
    3 Star Lounger rcbjr2's Avatar
    Join Date
    Jan 2001
    Location
    Matthews, NC
    Posts
    279
    Thanks
    6
    Thanked 1 Time in 1 Post

    Re-Save MS Word 2007 Doc from Sharepoint Site

    My company posts some template docs on a sharepoint site. Users are supposed to re-save a doc from the sharepoint site to their local drives when they save them. However, it seems that not all of the users do this and sometimes the original template is overwritten on the sharepoint site. I suspect that the administrators of the sharepoint site could set writes so that users cannot re-save the doc and write to the sharepoint site. However, I'm hoping I can do this with a macro in Word. Right now, I have the doc set up to run a macro upon opening to flash instructions to the user (one of which is to re-save the file elsewhere). However, most users gloss right over this. I have experimented a bit with ChDir(), but can't quite get anything to work. I've tried re-setting the save directory so that when the user tries to save the file it defaults to their local hard drive, but this doesn't work. The file save as still defaults to the sharepoint site. So, I'm hoping someone has a macro that will check to see if the directory is on a sharepoint site and then change it before the user uses the file save as command? I'm not sure I'm making complete sense or describing this completely, so if not please let me know. This has been frustrating me for several hours this morning. ;-)

    Thanks!

    -Rich

  2. #2
    3 Star Lounger
    Join Date
    Feb 2001
    Location
    Willow Grove, Pennsylvania, USA
    Posts
    205
    Thanks
    4
    Thanked 49 Times in 40 Posts
    The whole problem would be sidestepped by using real templates (.dotx or .dotm) instead of "template docs". Have each user point their Workgroup Templates folder to the SharePoint location, and use the New command instead of the Open command. That will create a document based on the template, and it will automatically request a new file name the first time it's saved. It would still be a good idea to have the SharePoint folder permissions set so that only the people who create and maintain templates are able to write to it -- ordinary users should not be able to "open" a template, only to "create new documents" from it (i.e., Read permission but not Write permission).

    The one complication occurs if the templates contain macros (and you won't need the macro you were working on ) -- then each user also has to go into the Trust Center > Trusted Locations and add the SharePoint folder as a trusted location to allow the macros to run.

    Both of these locations can be set up for the users by creating a .reg file in regedit.exe, containing the SharePoint folder's path in these entries:

    Key: HKEY_CURRENT_USER\Software\Microsoft\Office\12.0\C ommon\General
    Entry: SharedTemplates

    Key: HKEY_CURRENT_USER\Software\Microsoft\Office\12.0\W ord\Security\Trusted Locations\Location3
    Entry: Path

    (You might need to use a different number in place of Location3 if users already have non-default trusted locations.)
    Last edited by jjfreedman; 2012-08-21 at 13:32. Reason: fix typos

  3. #3
    3 Star Lounger rcbjr2's Avatar
    Join Date
    Jan 2001
    Location
    Matthews, NC
    Posts
    279
    Thanks
    6
    Thanked 1 Time in 1 Post
    Thanks for the suggestions. I tried using .DOT files (in case not everyone that grabs a template is using Word 2007 ). This wound up just opening the .DOT file for editing. There are embedded macros in the files. When the user opens the file, they have to click to allow the macros to run (mostly just a splash screen with instructions on how to complete the template). If we could fully educate the end users, or even trust them completely, or even go out and edit their registries (we're pretty locked down at work), we could adopt many of your suggestions, but I think I need something where the end user just has to click on the file on the sharepoint site and open it and then when they go to try to save it, the macros force it to be saved to a local drive and not the sharepoint site. While I can certainly follow your suggestions and could implement them personally, we really need something that is more automatic for the end user so that we can force the save on the local drive and not the templates sharepoint site.

    Thanks!

  4. #4
    3 Star Lounger
    Join Date
    Feb 2001
    Location
    Willow Grove, Pennsylvania, USA
    Posts
    205
    Thanks
    4
    Thanked 49 Times in 40 Posts
    When you say "This wound up just opening the .DOT file for editing", do you mean you were double-clicking the template in SharePoint? I haven't used SharePoint for a while so I don't remember what it does in that situation. In Window Explorer, the default double-click action for a .dot or .dotx/.dotm file is New instead of Open, so you would get a new file based on the template instead of just the template itself. Maybe that isn't true in SharePoint, although that would be kinda stupid.

    At any rate, you can write a macro named FileSaveAs in your document, and put into it the code shown at http://www.word.mvps.org/FAQs/Macros...SaveAsPath.htm. The most important unsaid thing there is to include the backslash at the end of the path you want to appear in the dialog.


  5. #5
    3 Star Lounger rcbjr2's Avatar
    Join Date
    Jan 2001
    Location
    Matthews, NC
    Posts
    279
    Thanks
    6
    Thanked 1 Time in 1 Post
    Thanks for idea about using SaveAsPath. I believe that is going to work. Of course, a user can still click cancel and wreak havoc, but it's a start.

    WRT your questions about opening .DOT files, they just open up in edit mode and not as a new un saved doc. I wish they opened up as the later because that would certainly solve my dilemma.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •