Printable Version of Topic

Click here to view this topic in its original format

UtterAccess Forums _ Access Date + Time _ Date Data Type Changed To Numbers

Posted by: Flacon88 Jun 13 2019, 03:12 PM

Hiii all

I have a field on a form its data type is date, its dafault value is system date, today when add new record to that form i surprised the date field is numbers (no date ).

Note ; the system date is right .

Please help.

Posted by: theDBguy Jun 13 2019, 03:13 PM

Hi. You said "form." What is the data type in the table?

Posted by: Flacon88 Jun 13 2019, 03:25 PM

Table has :

VisitID: Long (Pk)
VisitDate: date/time (the field that changet to numbers ).
DoctorRefer: text.

Posted by: theDBguy Jun 13 2019, 03:37 PM

Well, dates are just numbers anyway. So, when you said it changed to numbers, is this by looking at the values in the table?

Posted by: Flacon88 Jun 13 2019, 03:46 PM

No, this appears on the form .

I don't looking to the table .

Posted by: WildBird Jun 13 2019, 03:50 PM

Can you show what numbers they are showing? Screenshots help.

Is the number something close to 43630 by any chance?

Posted by: theDBguy Jun 13 2019, 03:52 PM

If only on the form, then perhaps you just need to set/select the proper Format for it. But, if you look at the table, do you see dates or numbers?

Posted by: Flacon88 Jun 13 2019, 04:03 PM

This is not able this time.

But i thinking numbers is like you reply.

Note: the db is in accde format

Posted by: Flacon88 Jun 16 2019, 10:07 PM

See to visit date :



 

Posted by: MadPiet Jun 16 2019, 10:17 PM

That's a form, not a table. =) The problem with showing a form is that it allows you to change the way the data in the table is represented, and folks here are trying to see past that. And dates/times are stored as numbers under the covers anyway. The integer portion is the number of days since some date in 1752 (I think) and then the decimal portion is the time.

Posted by: gemmathehusky Jun 17 2019, 04:14 AM

what IS 15,6,19166

It's not a valid date. Is there a regional setting that allows commas as date separators? Even so, the year can't be right, and the month would have a leading zero.

What is the format and data source of the control on your form - it's hard to see how that entry can have been accepted in the table as a valid date.

Posted by: moke123 Jun 17 2019, 05:24 AM

QUOTE
Note: the db is in accde format

Do you have the Accdb file?
You wont be able to make any changes\Repairs to an Accde file.


Posted by: Flacon88 Jun 17 2019, 07:39 AM

The day and month parts of that field is right, the problem at the year part.

Note: the date format is (dd/mm/yyyy).

Posted by: cheekybuddha Jun 17 2019, 07:56 AM

Somewhere you have an incorrect format set - hopefully on the textbox.

It looks like a format: "dd,mm,yyddm"

With the form in design view, select the textbox. In the properties dialog look at the Format section under the Format tab, and also the Text Format section under the Data tab

Does it say anything in either of those places?

Also look at your table in design view. Select your date field and look in the Field Properties section. Is there anything in the Format section of the General tab?

If not, then perhaps the regional setting for your dates on your machine have been changed to use an incorrect format string.

hth,

d

Posted by: Flacon88 Jun 17 2019, 08:32 AM

QUOTE
Somewhere you have an incorrect format set - hopefully on the textbox.

It looks like a format: "dd,mm,yyddm"

With the form in design view, select the textbox. In the properties dialog look at theFormat section under the Format tab, and also the Text Format section under the Data tab

Does it say anything in either of those places?

Also look at your table in design view. Select your date field and look in the Field Properties section. Is there anything in the Formatsection of the General tab?

If not, then perhaps the regional setting for your dates on your machine have been changed to use an incorrect format string.


Thanks for all.

The visitdate field is a date/time data type, and format is dd\mm\yyyy , and user uses this database for more than one year without any problem , Suddenly this problem only appeared four days ago.

Posted by: cheekybuddha Jun 17 2019, 08:57 AM

So did you look in the other places I suggested?

Posted by: gemmathehusky Jun 17 2019, 11:14 AM

QUOTE
The day and month parts of that field is right, the problem at the year part.

Note: the date format is (dd/mm/yyyy).



Sorry, it just isn't right. A month would show as 06, not just 6, and you probably wouldn't see 19/06/19166

We need to know the field that is bound to the text box control VISIT DATE, and the format applied to VISIT DATE

Posted by: RJD Jun 17 2019, 11:42 AM

Hi: Pardon me for jumping in, but since we do not have your db to work with, we are left in the dark guessing.

I ran a quick test using several different mistakes in a Format for the year - and it looks like you might have formatted the date as ...

"dd/mm/yyy"

... the year as 3 y's rather than 4, resulting in year 19168 (for today's date, almost what you saw)... without showing an error.

So, if you can, check the format for the date (both in the table and the form) and see if it might simply be typed incorrectly.

Just some thoughts ...

HTH
Joe