Ceejay64
Bass Playin' Biker Chick
- Local time
- Today, 13:43
- Joined
- Oct 2, 2002
- Messages
- 74
Hello All,
I am having an issue with the DTPicker control. Here's the scoop:
I have several of these controls on a subform and they are all set to the custom default (format: 3 - dtpCustom) of MM/dd/yy hh:mm:tt
I also have "on current" code that tells the form to hide the controls if they have already had a selection made (based on other fields containing the chosen dates) and show them if not. All of this works just great for the most part...
My problem comes up when a user has to scroll through to another record. The DTPicker controls seem to totally disregard the custom default format if the current record does not have a selection made for that field, but did for the previous record, and it no longer shows the time. It changes to my default date/time to a date only - in the format of MM/dd/yyyy with no time option.
Having both the date and time options is critical for my purposes. And because I have a ton of required fields on the page and have to connect the dates and times for later uses, it's not a practicle option to make a field for both.
Has anyone else had this problem, and does anyone have any suggestions for correcting it? I've tried to set a default matching what I need in the code for the form, but that failed to correct the problem. One other possibility - these controls are set to receive (as a starting point) a date/time from another field "on got focus" if that previous field has a value. These fields that feed the controls are set to "general date" with the same format, so I wouldn't think that would cause the problem, but I'm not sure that they aren't to blame. I can't set a default value in them, though, because that would cause errors.
I hope this post hasn't been monumentally confusing, and I would appreciate any ideas on how to get this straightened out.
Thanks in advance,
Ceejay
I am having an issue with the DTPicker control. Here's the scoop:
I have several of these controls on a subform and they are all set to the custom default (format: 3 - dtpCustom) of MM/dd/yy hh:mm:tt
I also have "on current" code that tells the form to hide the controls if they have already had a selection made (based on other fields containing the chosen dates) and show them if not. All of this works just great for the most part...
My problem comes up when a user has to scroll through to another record. The DTPicker controls seem to totally disregard the custom default format if the current record does not have a selection made for that field, but did for the previous record, and it no longer shows the time. It changes to my default date/time to a date only - in the format of MM/dd/yyyy with no time option.
Having both the date and time options is critical for my purposes. And because I have a ton of required fields on the page and have to connect the dates and times for later uses, it's not a practicle option to make a field for both.
Has anyone else had this problem, and does anyone have any suggestions for correcting it? I've tried to set a default matching what I need in the code for the form, but that failed to correct the problem. One other possibility - these controls are set to receive (as a starting point) a date/time from another field "on got focus" if that previous field has a value. These fields that feed the controls are set to "general date" with the same format, so I wouldn't think that would cause the problem, but I'm not sure that they aren't to blame. I can't set a default value in them, though, because that would cause errors.
I hope this post hasn't been monumentally confusing, and I would appreciate any ideas on how to get this straightened out.
Thanks in advance,
Ceejay