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 / October 2007

Tip: Looking for answers? Try searching our database.

Concatenate date parts and times... getting invalid date errors.

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
sboyd - 19 Oct 2007 19:35 GMT
I have 1 field - Plan_Depart_Date that is a date picker field
formatted with no time,
1 field that is a 2 character text field that is for the user to input
an Hr (in military time)
1 field that is a 2 character text field that is for the user to input
a Mn (in miliaray time)

I have a rule set on the Minute field if that a date is present in the
Plan_Depart_Date and a Min is present to set the value on a 4th
Plan_Depart_Time (Date time) field to

concat(substring(@Planned_Departing_Date, 6, 2), "-",
(substring(@Planned_Departing_Date, 9, 2)), "-",
(substring(@Planned_Departing_Date, 1, 4)), " ", @P_Depart_Time_Hr,
":", ., ":00")

Its coming out like this
10-2-2007 24:13:00 and is giving an invalid date message.  I need it
to come out as a valid date/Time and looking like this
10-2-2007 11:13 PM.

I've tried a number of variations to get this and I have had no luck.
Does anyone know the secret answer?
Clay Fox - 22 Oct 2007 08:21 GMT
Did you try looking at a now() with out formatting and putting a 'T' in
between the date and time?
Signature

Thanks

Clay Fox

Qdabra Software
http://www.qdabra.com

InfoPathDev.Com
The Largest InfoPath Forum in the World
http://www.infopathdev.com

> I have 1 field - Plan_Depart_Date that is a date picker field
> formatted with no time,
[quoted text clipped - 19 lines]
> I've tried a number of variations to get this and I have had no luck.
> Does anyone know the secret answer?
 
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.