...and I don't mean the fruity kind.
I think this forum is now going to be a bit more active these days! Anyway...
I've been seeing this error a number of times - when trying to compile things recently (and, in case you're curious - I used an online OCR tool to convert the pic of the error to Txt!): ************************** Error number: 2032 Error message: Ambiguous date/datetime constant. Use the format:
{yyvy-mm-dd{. [hh:mm:ss] [alp]]} Line number of error: 51 Command with error: IF thisform.txtDueDate. Value < {1/1/1990} OR thisform.txtDueDate. Value > {12/31/2049} Program with error: MPSBATCHTRANSFER.CMDACCEPT.CLICK
The error has been recorded in our error log for our future reference, **************************
I know that this method of encoding dates in VFP ( the {1/1/1990} style) is indeed an older method. But, at some point - did VFP just simply drop the support of this style of dates usage?
I'm honestly just curious...
-Kurt (The OLD VFP Guy who is now Back in the Saddle!)
Hi Kurt,
those dates are ambiguous because different cultures use different date formats (d/m/y or m/d/y or y/m/d).
I tend to code all my dates using DATE(2025, 3, 26) for example.
you can also check the help on SET STRICTDATE
Frank.
Frank Cazabon
On 26/03/2025 8:28 am, Kurt Wendt wrote:
...and I don't mean the fruity kind.
I think this forum is now going to be a bit more active these days! Anyway...
I've been seeing this error a number of times - when trying to compile things recently (and, in case you're curious - I used an online OCR tool to convert the pic of the error to Txt!):
Error number: 2032 Error message: Ambiguous date/datetime constant. Use the format:
{yyvy-mm-dd{. [hh:mm:ss] [alp]]} Line number of error: 51 Command with error: IF thisform.txtDueDate. Value < {1/1/1990} OR thisform.txtDueDate. Value > {12/31/2049} Program with error: MPSBATCHTRANSFER.CMDACCEPT.CLICK
The error has been recorded in our error log for our future reference,
I know that this method of encoding dates in VFP ( the {1/1/1990} style) is indeed an older method. But, at some point - did VFP just simply drop the support of this style of dates usage?
I'm honestly just curious...
-Kurt (The OLD VFP Guy who is now Back in the Saddle!)
[excessive quoting removed by server]
Thanks for the quick feedback Frank. I will indeed look at that StrictDate setting - as it's not a setting I've seen before nor used.
-K ________________________________ From: ProFox profox-bounces@leafe.com on behalf of Frank Cazabon frank.cazabon@gmail.com Sent: Wednesday, March 26, 2025 8:49 AM To: profox@leafe.com profox@leafe.com Subject: Re: An Issue with Dates...
[You don't often get email from frank.cazabon@gmail.com. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
Hi Kurt,
those dates are ambiguous because different cultures use different date formats (d/m/y or m/d/y or y/m/d).
I tend to code all my dates using DATE(2025, 3, 26) for example.
you can also check the help on SET STRICTDATE
Frank.
Frank Cazabon
On 26/03/2025 8:28 am, Kurt Wendt wrote:
...and I don't mean the fruity kind.
I think this forum is now going to be a bit more active these days! Anyway...
I've been seeing this error a number of times - when trying to compile things recently (and, in case you're curious - I used an online OCR tool to convert the pic of the error to Txt!):
Error number: 2032 Error message: Ambiguous date/datetime constant. Use the format:
{yyvy-mm-dd{. [hh:mm:ss] [alp]]} Line number of error: 51 Command with error: IF thisform.txtDueDate. Value < {1/1/1990} OR thisform.txtDueDate. Value > {12/31/2049} Program with error: MPSBATCHTRANSFER.CMDACCEPT.CLICK
The error has been recorded in our error log for our future reference,
I know that this method of encoding dates in VFP ( the {1/1/1990} style) is indeed an older method. But, at some point - did VFP just simply drop the support of this style of dates usage?
I'm honestly just curious...
-Kurt (The OLD VFP Guy who is now Back in the Saddle!)
[excessive quoting removed by server]
Hi Kurt,
not a setting I've seen before<<
I had to GROK that: https://x.com/i/grok/share/2RTNOjxbo9XPbisicDacYJd0v (For English scroll down)
<g> :=)
wOOdy
-----Ursprüngliche Nachricht----- Von: ProFox profox-bounces@leafe.com Im Auftrag von Kurt Wendt Gesendet: Mittwoch, 26. März 2025 13:55 An: ProFox Email List profox@leafe.com Betreff: Re: An Issue with Dates...
Thanks for the quick feedback Frank. I will indeed look at that StrictDate setting - as it's not a setting I've seen before nor used.
OK - figured I should follow up on this - for proper closure. Mainly for anyone who has a similar problem and wanted to know the outcome of my issue...
Turns out - the StrictDate setting was a value of "1" for my FoxPro. I was looking at the main VFP Options screen with Wayne - and I noticed it was showing a setting of "0". Even in my VPF for the Options screen - it was showing "0". However, I realized if I hit OK on that screen (previously I hit Cancel so that I didn't make ANY Options parameter changes) - that by hitting OK - it changed my setting to the "0" value. After doing that - I no longer got the error messages - not during compile time, nor at runtime.
So - Thanks again Frank for your advice and pointing me in the right direction!!!
It just proves again how valuable this Forum is - when you run into difficulties! I've gotten some amazing help here over the years.
I will also make one more interesting comment... That is...
I was thinking to myself the other day, about how I had not done serious programming work in VFP since - essentially - 2017. And, yet - now that I'm doing it again - it's like I just jumped right back in the Saddle - and I can easily crank out code and solve issues. So, in this case - it's like VFP is firmly Engraved in my Skull!
Unlike something else that happened years ago...
I had played the Sax - all the way from like 5th grade thru to being a Sr. in high school. Then I didn't touch the sax again until about maybe 1993 (I graduated high school in 1981). Well, in around 1993 - I picked up my sax, picked up some sheet music - and suddenly realized I could NOT Play anymore! Mainly, as in - I could no longer read sheet music and what notes equated to what finger positions on the saxophone.
After that - I would relate the story to folks - that the old phrase of "Use it Or Lose It" - I found out it was Completely TRUE!
Luckily it was NOT try in my case with my baby VFP!!!
Ciao for now, -Kurt the VFP Guy who is Back In The Saddle!
________________________________ From: ProFox profox-bounces@leafe.com on behalf of Kurt Wendt kwendt@pakoinc.com Sent: Wednesday, March 26, 2025 8:54 AM To: ProFox Email List profox@leafe.com Subject: Re: An Issue with Dates...
Thanks for the quick feedback Frank. I will indeed look at that StrictDate setting - as it's not a setting I've seen before nor used.
-K ________________________________ From: ProFox profox-bounces@leafe.com on behalf of Frank Cazabon frank.cazabon@gmail.com Sent: Wednesday, March 26, 2025 8:49 AM To: profox@leafe.com profox@leafe.com Subject: Re: An Issue with Dates...
[You don't often get email from frank.cazabon@gmail.com. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
Hi Kurt,
those dates are ambiguous because different cultures use different date formats (d/m/y or m/d/y or y/m/d).
I tend to code all my dates using DATE(2025, 3, 26) for example.
you can also check the help on SET STRICTDATE
Frank.
Frank Cazabon
On 26/03/2025 8:28 am, Kurt Wendt wrote:
...and I don't mean the fruity kind.
I think this forum is now going to be a bit more active these days! Anyway...
I've been seeing this error a number of times - when trying to compile things recently (and, in case you're curious - I used an online OCR tool to convert the pic of the error to Txt!):
Error number: 2032 Error message: Ambiguous date/datetime constant. Use the format:
{yyvy-mm-dd{. [hh:mm:ss] [alp]]} Line number of error: 51 Command with error: IF thisform.txtDueDate. Value < {1/1/1990} OR thisform.txtDueDate. Value > {12/31/2049} Program with error: MPSBATCHTRANSFER.CMDACCEPT.CLICK
The error has been recorded in our error log for our future reference,
I know that this method of encoding dates in VFP ( the {1/1/1990} style) is indeed an older method. But, at some point - did VFP just simply drop the support of this style of dates usage?
I'm honestly just curious...
-Kurt (The OLD VFP Guy who is now Back in the Saddle!)
[excessive quoting removed by server]
Yippee-Ki-Yay!
Paul H. Tarver Tarver Program Consultants, Inc.
-----Original Message----- From: ProfoxTech [mailto:profoxtech-bounces@leafe.com] On Behalf Of Kurt Wendt Sent: Thursday, March 27, 2025 12:05 PM To: profoxtech@leafe.com Subject: Re: An Issue with Dates...
OK - figured I should follow up on this - for proper closure. Mainly for anyone who has a similar problem and wanted to know the outcome of my issue...
Turns out - the StrictDate setting was a value of "1" for my FoxPro. I was looking at the main VFP Options screen with Wayne - and I noticed it was showing a setting of "0". Even in my VPF for the Options screen - it was showing "0". However, I realized if I hit OK on that screen (previously I hit Cancel so that I didn't make ANY Options parameter changes) - that by hitting OK - it changed my setting to the "0" value. After doing that - I no longer got the error messages - not during compile time, nor at runtime.
So - Thanks again Frank for your advice and pointing me in the right direction!!!
It just proves again how valuable this Forum is - when you run into difficulties! I've gotten some amazing help here over the years.
I will also make one more interesting comment... That is...
I was thinking to myself the other day, about how I had not done serious programming work in VFP since - essentially - 2017. And, yet - now that I'm doing it again - it's like I just jumped right back in the Saddle - and I can easily crank out code and solve issues. So, in this case - it's like VFP is firmly Engraved in my Skull!
Unlike something else that happened years ago...
I had played the Sax - all the way from like 5th grade thru to being a Sr. in high school. Then I didn't touch the sax again until about maybe 1993 (I graduated high school in 1981). Well, in around 1993 - I picked up my sax, picked up some sheet music - and suddenly realized I could NOT Play anymore! Mainly, as in - I could no longer read sheet music and what notes equated to what finger positions on the saxophone.
After that - I would relate the story to folks - that the old phrase of "Use it Or Lose It" - I found out it was Completely TRUE!
Luckily it was NOT try in my case with my baby VFP!!!
Ciao for now, -Kurt the VFP Guy who is Back In The Saddle!
________________________________ From: ProFox profox-bounces@leafe.com on behalf of Kurt Wendt kwendt@pakoinc.com Sent: Wednesday, March 26, 2025 8:54 AM To: ProFox Email List profox@leafe.com Subject: Re: An Issue with Dates...
Thanks for the quick feedback Frank. I will indeed look at that StrictDate setting - as it's not a setting I've seen before nor used.
-K ________________________________ From: ProFox profox-bounces@leafe.com on behalf of Frank Cazabon frank.cazabon@gmail.com Sent: Wednesday, March 26, 2025 8:49 AM To: profox@leafe.com profox@leafe.com Subject: Re: An Issue with Dates...
[You don't often get email from frank.cazabon@gmail.com. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
Hi Kurt,
those dates are ambiguous because different cultures use different date formats (d/m/y or m/d/y or y/m/d).
I tend to code all my dates using DATE(2025, 3, 26) for example.
you can also check the help on SET STRICTDATE
Frank.
Frank Cazabon
On 26/03/2025 8:28 am, Kurt Wendt wrote:
...and I don't mean the fruity kind.
I think this forum is now going to be a bit more active these days!
Anyway...
I've been seeing this error a number of times - when trying to compile
things recently (and, in case you're curious - I used an online OCR tool to convert the pic of the error to Txt!):
Error number: 2032 Error message: Ambiguous date/datetime constant. Use the format:
{yyvy-mm-dd{. [hh:mm:ss] [alp]]} Line number of error: 51 Command with error: IF thisform.txtDueDate. Value < {1/1/1990} OR thisform.txtDueDate. Value > {12/31/2049} Program with error: MPSBATCHTRANSFER.CMDACCEPT.CLICK
The error has been recorded in our error log for our future reference,
I know that this method of encoding dates in VFP ( the {1/1/1990} style)
is indeed an older method. But, at some point - did VFP just simply drop the support of this style of dates usage?
I'm honestly just curious...
-Kurt (The OLD VFP Guy who is now Back in the Saddle!)
[excessive quoting removed by server]