Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 8854 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

I've designed a date field to set the current date (via scripted button) and formatted the date to appear as Saturday, August 26, 2000. The button option is in case the user needs to post date their written report. I field tested the layout by creating several fictitious discipline reports. Everything went perfect till I highlighted the date field to clear it and watched it revert to 8/26/2000. Although it's unlikely this date will ever be cleared, the switch still bothers me. Maybe I've chosen the worng way to get the current date...

SetField ["Date 1", "Today"]. What have I missed?

Posted

Hey tmac,

Here's what's happening.

You created a field called DATE1 and set the type to DATE. When you set the field on your layout, you went to the date format and set that to <day of week>, <month> <date>, <year>.

In your script using the command SET FIELD ["DATE1","Toaday"] will pass the date information to the DATE1 field in the format of mm/dd/yyyy.

When you click on the field, you will see the information as it was passed, not as you formatted it for displaying.

If you think the change of the display may bother someone, set the field so it cannot be modified from the layout. Go to the field format and un-check Allow entry into field.

Hope this helped. smile.gif

Steve

This topic is 8854 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.