Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 11-11-2010, 06:15 AM
mcarter9000 mcarter9000 is offline Date auto-populates based on checkbox Windows XP Date auto-populates based on checkbox Office 2007
Novice
Date auto-populates based on checkbox
 
Join Date: Nov 2010
Posts: 3
mcarter9000 is on a distinguished road
Unhappy Date auto-populates based on checkbox

I am not anywhere near an expert in programming - so I need some assistance.

I need to create a form that includes check boxes and date fields. When the user checks the box, a date needs to auto-populate next to the box.

Can someone provide the VB for this as well as instructions on how to insert in to the document?

Thanks in advance.
Reply With Quote
  #2  
Old 12-22-2010, 11:12 PM
macropod's Avatar
macropod macropod is offline Date auto-populates based on checkbox Windows 7 32bit Date auto-populates based on checkbox 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 mccarter,

Is this a userform, or a document using formfields? Also, what determines the date and its location in the document (if that's where it is to go)?

Cheers,
Paul Edstein
[MS MVP - Word]
Reply With Quote
  #3  
Old 12-22-2010, 11:52 PM
mcarter9000 mcarter9000 is offline Date auto-populates based on checkbox Windows XP Date auto-populates based on checkbox Office 2007
Novice
Date auto-populates based on checkbox
 
Join Date: Nov 2010
Posts: 3
mcarter9000 is on a distinguished road
Default Date auto-populates based on checkbox

The need is for a user form - and the date to populate next to the checkbox would be the current date which of course would not change when the form is saved and re-opened - the goal is to have a date record of when a task was completed, without asking the user to enter the date.
Reply With Quote
  #4  
Old 12-23-2010, 12:38 AM
macropod's Avatar
macropod macropod is offline Date auto-populates based on checkbox Windows 7 32bit Date auto-populates based on checkbox 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 mccarter,
Quote:
Originally Posted by mcarter9000 View Post
The need is for a user form - and the date to populate next to the checkbox would be the current date which of course would not change when the form is saved and re-opened - the goal is to have a date record of when a task was completed, without asking the user to enter the date.
OK, then, have you created the basic form with the checkbox & text items? If so, what are the checkbox object names and the corresponding textbox object names? If not, you'll need to do this before you can progress.

Also, since you want to keep the dates once they've been created, you're going to need somewhere in the document to store them - either a custome document property for each date or a table or a bookmark, or something such. Have you given any thought to this and, if so, how are the relevant storage places identified?

Cheers,
Paul Edstein
[MS MVP - Word]
Reply With Quote
  #5  
Old 12-23-2010, 07:48 AM
mcarter9000 mcarter9000 is offline Date auto-populates based on checkbox Windows XP Date auto-populates based on checkbox Office 2007
Novice
Date auto-populates based on checkbox
 
Join Date: Nov 2010
Posts: 3
mcarter9000 is on a distinguished road
Default

I had not thought about the need to name the fields and checkboxes as I have not had to do this before - but to name them, the convention I would follow would be something like this:

LoanTypeConfirmed (checkbox)
LoanTypeDate (field for date auto-post)

And then as to date storage - I would create a summary section on the document that would list the tasks and the dates.

Task (Heading) Date (Heading)
Loan Type Confirmed Date from field listed above

Martha
Reply With Quote
  #6  
Old 12-23-2010, 12:39 PM
macropod's Avatar
macropod macropod is offline Date auto-populates based on checkbox Windows 7 32bit Date auto-populates based on checkbox 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 Martha,

I'm still not sure why you believe a userform is needed, since the data need to be stored on a page in the document.

Consider the attached dummy form that asks whether a series of checks have been done and, if so, inputs the current date next to it. Checking/unchecking the checkboxes inserts/deletes the date, and comments may be added. There is a simple macro attached to the checkbox formfields, which you can access via Alt-F11. You can also toggle the forms protection on/off so that you can see how I've configured the formfield properties.

Cheers,
Paul Edstein
[MS MVP - Word]
Attached Files
File Type: doc Checks.doc (43.5 KB, 36 views)
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Creating an Auto-Calc'd Date? Today+7 Days? SoCalTelephone Word 0 10-06-2010 10:27 AM
Date auto-populates based on checkbox Auto date alarm? markg2 Excel 3 11-18-2009 08:25 AM
new appointment date always reverts back to today's date msills Outlook 0 08-24-2007 08:57 AM
resizing a checkbox?? aceensor Excel 0 05-10-2006 01:44 PM
Date auto-populates based on checkbox Imported message date change to today's date promark Outlook 1 12-23-2005 07:21 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 03:41 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