473,395 Members | 1,647 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Text to Date field in Access

35 32bit
I am trying to subtract 2 dates in Access, however they are currently in text fields and I cannot subtract. Is there any way to change them to a date field?
Aug 28 '12 #1
3 1712
Seth Schrock
2,965 Expert 2GB
So are you trying to find out how many days are between those two dates? If so, then you would use the DateDiff() function. You would then have an unbound textbox that uses this as it default value. Here is more information about the DateDiff() function: Calculate the difference between two date or time values
If you are looking to add a certain about of time to a date, then you would use the DateAdd() function. MS Access: DateAdd Function
Aug 29 '12 #2
zmbd
5,501 Expert Mod 4TB
rhonda6373:
You have not provided enough information.
Where are the fields located?
What format is the date in?
Where are you trying to do the calculation?
-z
Aug 29 '12 #3
NeoPa
32,556 Expert Mod 16PB
Yes Rhonda. The CDate() function will do that for you.
Aug 30 '12 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Fran Zablocki | last post by:
I have a process that exports an Access table to a comma-delimited text file. One of the fields that is exported shows the date it was exported, using the Date() function. In the Access table, the...
1
by: Liz Malcolm | last post by:
Hello and TIA. I have a DE form with an option group that if daily is selected todays date is used for start and end date, if weekly is selected Monday - Friday is used. I am trying to add a...
1
by: paulquinlan100 | last post by:
Hi I have a date field which when i enter the date in some places, works fine, however, when trying to enter dates on certain rows i get the message: "The value you entered isn't valid for...
1
by: Graham Feeley | last post by:
I have a date field named rcdate it is a general date eg: 12/08/2006 3:30:00 PM 12/08/2006 3:00:00 PM I used to update another empty field named rdate with the with using in a update query "...
1
by: wwolford | last post by:
I am using MS Query to pull files (from IBM AS400) and put them in Excel. However, when I do this the dates are now text fields. The text/ Date field looks like this: 20070331 (YYYYMMDD) I...
3
by: Finn Stampe Mikkelsen | last post by:
Hi I have defined a table in my database, with 2 date-fields. I have set a default value to DBNull. I have integrated a nullable datetimepicker control to my project and set the apropriate...
1
by: Thorben Grosser | last post by:
Hey again newsgroup, I am still working on an archive database and got another problem: I have to classify the folders by a date or a date range which has the format mm/yyyy I got the feeling,...
7
by: sheri | last post by:
I have a field called date, the date is in the field like this 70925 (which means Sept. 25, 2007). I have another field called day, it is a text field. How do I write a query to populate the day...
1
by: ndeeley | last post by:
Okay... I've created a drop down list fed by a table. I want my users to select an item in the list, say `Awaiting Repairs`, then fill in a single date text field. When a command button is pressed...
2
by: Mimi | last post by:
In Access 2007, I have successfully imported a text file with fixed width fields. However the import did not correctly interpret a date. In the text file the date field had no delimiter, was just...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.