Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / General MS InfoPath Questions / April 2005

Tip: Looking for answers? Try searching our database.

Form validation and Date datatype

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
TimPGade - 07 Mar 2005 16:33 GMT
It is my understanding that if a field/element is a Date (date)  Data type
then the form field cannot be blank at validation. To allow blank values I
need to change the Data type to Text (string).

Is there any other way to have the field as a Date and allow a blank date as
a valid value or do I need to make it a string and then check for a valid
date if not blank?

Signature

Get what you expect from technology!

TimPGade - 25 Mar 2005 22:57 GMT
Can somebody direct me to an answer for this? It's been 3 weeks since I
posted it.

> It is my understanding that if a field/element is a Date (date)  Data type
> then the form field cannot be blank at validation. To allow blank values I
[quoted text clipped - 3 lines]
> a valid value or do I need to make it a string and then check for a valid
> date if not blank?
Ross Culver - 26 Mar 2005 05:20 GMT
Tim,

Where did you hear that you couldn't validate against a blank date field?
Or to be more exact, a datepicker object?  I have a rule in my validation
that ensures that the user must enter a date in the datepicker and this
validation works fine.

Ross

> Can somebody direct me to an answer for this? It's been 3 weeks since I
> posted it.
[quoted text clipped - 9 lines]
>> a valid value or do I need to make it a string and then check for a valid
>> date if not blank?
TimPGade - 26 Mar 2005 07:11 GMT
Just the opposite. I want to allow a blank date but the datepicker is
expecting a valid one.

> Tim,
>
[quoted text clipped - 18 lines]
> >> a valid value or do I need to make it a string and then check for a valid
> >> date if not blank?
Ross Culver - 27 Mar 2005 05:17 GMT
I guess the question then is, what is a valid value to validate.  You can't
enter a value that isn't equal to a date in a datepicker, so there's you're
validation.  And you can leave a datepicker blank.

Ok, try this (again, I'm assuming that you're using a datepicker and not
just a textbox), set your validation to use two conditions against the date
field 1) that it isn't blank AND that it's, I don't know, maybe greater than
a certain date.  In other words, whatever the conditions if you include that
it isn't blank and another condition then it should allow blank that meet
the second condition.

Make sense?

Ross

> Just the opposite. I want to allow a blank date but the datepicker is
> expecting a valid one.
[quoted text clipped - 24 lines]
>> >> valid
>> >> date if not blank?
TimPGade - 09 Apr 2005 18:39 GMT
Hi Ross,

The prolem I am having is that I am loading NUll dates from MSAccess (for
example DateComplete) into a secondary DOM and copying the values into the
main datasource. When I try to submit the form the datepicker wants a
datevalue for these fields. I will have to revisit this to outline the
specific steps I am taking.

Tim

> I guess the question then is, what is a valid value to validate.  You can't
> enter a value that isn't equal to a date in a datepicker, so there's you're
[quoted text clipped - 39 lines]
> >> >> valid
> >> >> date if not blank?
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.