Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 04-08-2011, 11:29 AM
vishal17 vishal17 is offline Add/Delete data in a Document based on User info Windows XP Add/Delete data in a Document based on User info Office 2007
Novice
Add/Delete data in a Document based on User info
 
Join Date: Apr 2011
Posts: 3
vishal17 is on a distinguished road
Default Add/Delete data in a Document based on User info


I have a single document with all the info, I want to create a Form (with checkbox) on top of it where Users can select what data they want to assemble in the word document. How can it be done? Are there any 3rd party tools that can do that?
Reply With Quote
  #2  
Old 04-08-2011, 06:45 PM
macropod's Avatar
macropod macropod is offline Add/Delete data in a Document based on User info Windows 7 32bit Add/Delete data in a Document based on User info Office 2000
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 21,956
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Hi vishal,

There are various ways of doing this, requiring the use of either a userform of a series of formfields to determine what gets output. Userforms have the advantage of not being part of the actual document - they simply sit over it to provide an interface for whatever is being done to the document beneath. Form fields sit in the actual document, but can be put on a single page that perhaps doesn't get printed (or can be printed to confirm what choices were made).

As a rule, it's unsafe to simply delete 'unwanted' text as there's then no way of restoring it if the user changes their mind. Accordingly, it's preferable to either:
1. store the variable text in the macro itself, and update bookmarks in the document with/without the text; or
2. store the variable text in fields within the document, then toggle their output on/off via edits to custom document properties.

Clearly, there are some design issues you'll need to think about before you can go much further.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
  #3  
Old 04-13-2011, 01:54 PM
vishal17 vishal17 is offline Add/Delete data in a Document based on User info Windows XP Add/Delete data in a Document based on User info Office 2007
Novice
Add/Delete data in a Document based on User info
 
Join Date: Apr 2011
Posts: 3
vishal17 is on a distinguished road
Default Thanks Paul

I have created the Form and is working great.

I am at a point where I want to delete stuff based on the form selection.

I have the following structure:

1. Collect IIS
text, text,text, text,text, text,text, text,text, text,
text, text,text, text,text, text,

2. Collect Apache
text, text,text, text,text, text,text, text,text, text,
text, text,text, text,text, text,

If the User Select Apache - I want to delete IIS Section - Please let me know if this can be done
Reply With Quote
  #4  
Old 04-13-2011, 02:18 PM
macropod's Avatar
macropod macropod is offline Add/Delete data in a Document based on User info Windows 7 32bit Add/Delete data in a Document based on User info Office 2000
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 21,956
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Hi vishal,

Are you proposing to simple delete the text with no means of recovery?

Is the 'form' a userform, or a series of formfields?

Are the ranges you might want to delete bookmarked? If not how do you propose they be identified?
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
  #5  
Old 04-14-2011, 11:27 AM
vishal17 vishal17 is offline Add/Delete data in a Document based on User info Windows XP Add/Delete data in a Document based on User info Office 2007
Novice
Add/Delete data in a Document based on User info
 
Join Date: Apr 2011
Posts: 3
vishal17 is on a distinguished road
Default Answers

***Are you proposing to simple delete the text with no means of recovery?
Well it is going to be a template, which has 100 pages. Based on User selection I will delete 80 Pages and they can save the document under another name.

***Is the 'form' a userform, or a series of formfields?
Yes, it is User Form.

***Are the ranges you might want to delete bookmarked? If not how do you propose they be identified?
Thats where I am stuck - not sure how I can do that.
How do I bookmark a Section/paragraph. And delete/keep based on the user input.
Reply With Quote
  #6  
Old 04-14-2011, 05:02 PM
macropod's Avatar
macropod macropod is offline Add/Delete data in a Document based on User info Windows 7 32bit Add/Delete data in a Document based on User info Office 2000
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 21,956
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Quote:
Originally Posted by vishal17 View Post
***Are the ranges you might want to delete bookmarked? If not how do you propose they be identified?
Thats where I am stuck - not sure how I can do that.
How do I bookmark a Section/paragraph. And delete/keep based on the user input.
Simply select the range you want to be able to delete, then go to Insert|Bookmark and add a bookmark name. Note: each separate range must have its own bookmark - two ranges cannot have the same bookmark.

Attached is a simple demo. The text in red has been bookmarked. Clicking on the checkbox on the formfield deletes that range.
Attached Files
File Type: doc DeletionDemo.doc (45.5 KB, 14 views)
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Add/Delete data in a Document based on User info Default Custom Dictionary Based on Document PatrickYork Word 3 04-03-2015 11:19 PM
Look up an array based on user input johnsmb Excel 2 01-07-2011 01:12 PM
Add/Delete data in a Document based on User info Hidden Info in Document freschij Word 1 06-11-2010 12:35 PM
Is there a way to do this? (automatically enter text based on form data) TIKKI555 Word 0 05-26-2010 09:21 AM
Add/Delete data in a Document based on User info Can you and how, cause a http redirection when a user opens a word document avaintcon Word 1 09-02-2009 05:02 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 10:27 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft