Hi I have two questions the first one is how do you add time such as a list of minutes and seconds to get a total of time in a minute and second format. The second question is one I have asked before but I thought it was solved but it is back. My combo boxes work fine in all my forms and subforms until I shut down access. When I restart access and try to use my combo boxes none of them work. I still have the dropdown with all the info and I can pick them that way. So I redo a combo box (delete and rebuild it) any combo box in my database and they all work again with now problem. I can't figure this out. Can you help?
Scott Axton
@Reply 3 years ago
First of all what is the structure of your table and how are you storing your times?
Access stores a date and time as a number so it is very easy to add them together if you are set up correctly.
Check out TimeValue for a quick primer and watch / re-watch the videos at the end to learn more about Dates / Times.
-----------
Combo Boxes
That's an issue and makes absolutely no sense. I can think of two things right off the top of my head.
1. You are missing a step when making your Combo Box.
2. Your db is corrupted and you may need to take more drastic measures.
3. ???
In order to figure that out we need more info.
First - are you getting any errors? "Doesn't work" does not tell us much. What exactly is happening or not happening that should?
If you download a fresh copy of one of Richard's DBs, does the same thing happen there?
If no, then I would start out with a Compact & Repair.
Scott
This is a new database I created Three Days ago. It is some thing I created to try my knowledge of Access. It Is about my CD Music collection. The times I would like to add together are the times of each track on the CD. It would also apply to adding laps in a race to get total time. I watched the video you directed me to and that just don't apply to my situation.
As for the other I have tried all the steps you mentioned before and nothing seemed to work. The combo boxes are simple chose a name or a song from a form and put it on my subform. The form has all the information but when I begin typing it does not auto fill. I can Type the whole name and when I press enter or Tab I get an error message saying that it is not on the list. It then shows the list and and I have to scroll through the list and find it. When I click on it, it excepts it and goes on. I have two other databases that work fine. It must be something I am doing when I set It up. But I don't know what.
Richard Van WagonerOP
@Reply 3 years ago
Here are some screenshots of my tables and one combo box with its property sheet
Richard Van WagonerOP
@Reply 3 years ago
Richard Van WagonerOP
@Reply 3 years ago
Richard Van WagonerOP
@Reply 3 years ago
Richard Van WagonerOP
@Reply 3 years ago
Richard Van WagonerOP
@Reply 3 years ago
Richard Van WagonerOP
@Reply 3 years ago
Richard Van WagonerOP
@Reply 3 years ago
Richard Van WagonerOP
@Reply 3 years ago
Richard Van WagonerOP
@Reply 3 years ago
Richard Van WagonerOP
@Reply 3 years ago
Scott Axton
@Reply 3 years ago
Richard remember the litmus test for field types. Are you ever going to perform math on it?
In your case the Length field for length of the track the answer is yes. So that means that it should not be Short Text.
Instead it should be a Date/Time field. In essence Date / Time is a special kind of number for the purposes of Access.
Access knows that once you hit 60 seconds the number goes to 1 minute. Not 61 Seconds.
You don't have to put in a date if you just want the time. So you would enter it in as 01:32 (one minute, 32 Seconds)
If you want you can even add in an input mask or formatting to the field. Remember that Minute is "n" so something like hh:nn:ss - hours minutes seconds.
That way you can add up the lengths of the tracks to get the total play time for an album.
Pretty confusing I know.
To make things even more confusing (sorry) Access stores the date if you don't put it in whether or not you entered it. Access' 'zero' date is 12/31/1899. That is where the decided to start the clock so to speak.
That is where the TimeValue video above comes in. Another video that might help is the Total Time Spent.
Regarding the Combo Box I haven't been able to spend much time yet. I suspect that you are either not using the correct ID for the linking or Access is not making the relationship between the SubForm and the ParentForm correctly.
Double check that the IDs are set correctly. If needed review that Many-to-Many video again.
Richard Van WagonerOP
@Reply 3 years ago
I changed the Datatype for my Length Field. Now I have to type 0:nn:ss for my length, which is fine but when I run a sum on that field in my subform footer I get a weird number see screenshots. I am assuming that that is like time of day in number format . How do I fix this?
Richard Van WagonerOP
@Reply 3 years ago
Richard Van WagonerOP
@Reply 3 years ago
Kevin Robertson
@Reply 3 years ago
Check the Format property of the Total Length Text Box. It should be the same format as the field you are summing up.
Kevin Robertson
@Reply 3 years ago
Richard Van WagonerOP
@Reply 3 years ago
I Found out how to get a correct number for the sum. I formatted the box with the sum to hh:nn:ss and it worked. Thanks.
Sorry, only students may add comments.
Click here for more
information on how you can set up an account.
If you are a Visitor, go ahead and post your reply as a
new comment, and we'll move it here for you
once it's approved. Be sure to use the same name and email address.
This thread is now CLOSED. If you wish to comment, start a NEW discussion in
Access TechHelp.