09-08-2011 05:43 PM
Is there any way to set the default datetime value to 'Today' when creating a new record in a custom table?
It would be very nice if the FieldDescriptor would allow a DefaultValue attributes. Such as:
Me.FieldDescriptor.Attributes(Act.Framework.Database.FieldProperty.DefaultValue) = New Act.Framework.Database.DefaultValueAttribute("Today")
Can anybody think of way to achieve this without storing the "Today" value outside the ACT DB?
It needs to be able to sync to remotes and be backed up with the DB.
I don't think I can store it in the preferences since they would be user specific.
-- Jim Durkin
09-09-2011 08:54 AM
I'm not sure I understand what the goal is. Do you want the characters "Today" to show up in the field as a selection for the end user? If so then you could just create a custom control that would do it or am I missing something?
09-09-2011 09:03 AM
09-09-2011 09:54 AM
So if I understand correctly you want an attribute on a date field for "Today" that automatically sets it to today's date? That would be handy. While they're at it they probably should have a "Now" attribute for date and time.
09-09-2011 02:20 PM
Yes exactly. It would be nice if they enumed it also. Such as...
I would be extremely helpful if we could use the enums DefaultDateValue.Null instead of the nullable date value in .NET
Dim ReturnDate AsDate? = Nothing
System.DateTime? ReturnDate = null;
Feature request please!
-- Jim Durkin