Solved

Section of word document as read only ?

Posted on 2006-11-10
14
3,117 Views
Last Modified: 2008-08-22
I would like to be able to 'lock' parts of a word document.  Eg have a table and prevent the user modifying/deleting the contents of *SOME* cells in the table.  (Maybe an embedded field of some kind in the cell?)

The document will be created by automation and some information the end user is not allowed to modify or delete.

Is it possible? and if yes then how?  


BTW Having an embedded excel sheet is NOT an option.
0
Comment
Question by:AndyAinscow
  • 8
  • 4
  • 2
14 Comments
 
LVL 22

Expert Comment

by:Dreamboat
Comment Utility
Very difficult to lock PARTS of a table, but certainly not parts of a document. Here's my article that explains how:
http://www.officearticles.com/word/protecting_parts_of_a_document_in_microsoft_word.htm
0
 
LVL 44

Author Comment

by:AndyAinscow
Comment Utility
Thanks, I've had a quick look at the link.  It doesn't look suitable.  Unless I misunderstand it only works on 'horizontal stripes' that are the complete width of the document.

eg.
Table with 3 columns and 2 rows.
I might want to lock row 1, column 3 then row 2 columns 2 and 3
0
 
LVL 22

Accepted Solution

by:
Dreamboat earned 500 total points
Comment Utility
0
 
LVL 44

Author Comment

by:AndyAinscow
Comment Utility
I'll have to study it.
0
 
LVL 22

Expert Comment

by:Dreamboat
Comment Utility
Sorry...should have said....
You can put form fields into some of those table cells where you want users to have access.
Unfortunately, document protection of ANY section(s) disables lots of formatting, etc. You may be better off looking into VBA Userforms to pop up and enter data for the user into the appropriate areas. Not sure.
0
 
LVL 44

Author Comment

by:AndyAinscow
Comment Utility
It's for report generation.  Currently it is an Access report but there are too many requirements to modify how it looks now - so the thought of automating word and protecting the 'critical' information but allowing the user to modify the less important textual/formatting when required.  (word/line breaks, highlight a phrase....)
0
 
LVL 44

Author Comment

by:AndyAinscow
Comment Utility
ps - I should have said, Word 2003/XP
0
Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

 
LVL 21

Expert Comment

by:EricFletcher
Comment Utility
You could "cover" the parts you want to prevent users from inadvertently changing: insert a small image (a 1x1 pixel white GIF would do) and use Format Picture to place it in front of text, then use the Crop handles to extend the picture corners out over the table you want to cover. Now the table will be visible through the negatively-cropped image, and if a user clicks within it, they will be selecting the picture and not content.

Note that this approach would reduce indadvertent edits but won't stop someone from getting at the content if they really want to.

There may be a way to make the object into a button that would run code to pop up a warning dialog when a user clicked on it but I haven't tried doing that.
0
 
LVL 44

Author Comment

by:AndyAinscow
Comment Utility
Nice thought - it could be worth a try.
0
 
LVL 44

Author Comment

by:AndyAinscow
Comment Utility
Eric - do you know if one can stop the user resizing/deleting the picture.  (I thought that click, delete and the protection is away.  If the user wanted to modify the cell contents then they would first try clicking onto it.)
0
 
LVL 21

Expert Comment

by:EricFletcher
Comment Utility
Not readily... that's why I cautioned that it would only be an alert to a user.

While it would be nice to be able to assume users can actually think before acting, I realize that this is usually only a dream. Dreamboat's suggestion of using forms will offer more protection against changes from users who don't/can't read instructions, but nothing is really completely foolproof IMHO. Of course you can always do a document compare to be able to inspect all differences between an original and what you get back, but that can be a lot of work...

If you could set it up like a button in Excel (so you could attach code to run if it were clicked), you could perhaps prevent them from deleting the image object, but that is beyond my expertise I'm afraid. Perhaps others reading this question could suggest a method? (Or you could post a new question asking for the "how to" more specifically.)
0
 
LVL 44

Author Comment

by:AndyAinscow
Comment Utility
Thanks.
0
 
LVL 44

Author Comment

by:AndyAinscow
Comment Utility
Thanks - using forms should work
0
 
LVL 22

Expert Comment

by:Dreamboat
Comment Utility
Thanks, Andy. :)
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Suggested Solutions

The Selection object is designed for user interaction. It has a Range property, so it can be used in most places that a Range object can. Recorded macros must use the Selection because they are simply copying what the user is doing. A Range prope…
Preface: When I started this series, I used the term CommandBars because that is the Office Object class that it discusses. Unfortunately, when Microsoft introduced Office 2007, they replaced the standard Commandbar menus with "The Ribbon" and rem…
In this video, we show how to convert an image-only PDF file into a PDF Searchable Image file, that is, a file with both the image (typically from scanning) and text, which is created in an automated fashion with Optical Character Recognition (OCR) …
The viewer will learn how to make their project stand out over others by learning how to change colors and shapes, add spaces, change directions, and add bullets to their charts.

772 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

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now