‎10-12-2012 08:06 AM
What is the most efficienct way to convert a Time Stamp Control to a MM/DD/YYYY string? I am going to use its output as date parameters to a WHERE clause to a SQL Server query.
Solved! Go to Solution.
‎10-12-2012 08:09 AM - edited ‎10-12-2012 08:11 AM
Format Date/Time String is a simple option.
‎10-12-2012 08:20 AM - edited ‎10-12-2012 08:21 AM
I skipped right by that. I must not have had enough coffee yet this morning.
Thank you.
‎10-12-2012 08:24 AM
You're welcome
‎10-12-2012 08:26 AM
Those format codes can be tricky to write from scratch. I usually format a timestamp constant the way I want it displayed, switch to advanced format editing and copy the format string.
‎10-12-2012 08:33 AM
Jeff,
I just did it like this. Do you forsee any problems? I noticed yours had the greater than and less than math operators near the beginning and end of the format string.
‎10-12-2012 08:36 AM
@Eric1977 wrote:
Jeff,
I just did it like this. Do you forsee any problems?
Well, what is the output? Do you foresee a problem? The LabVIEW Help is quite clear on the format. The very first sentence of the Help file for the Format Date Time String provide a link to the codes: http://zone.ni.com/reference/en-XX/help/371361H-01/glang/codes_for_time_format_str/