Solved code no longer working (1 Viewer)

Isaac

Lifelong Learner
Local time
Yesterday, 19:46
Joined
Mar 14, 2017
Messages
8,777
I will admit that I'm not an expert at troubleshooting mistakes that are generated by differences in versions. I will bow out now and maybe someone else more knowledgeable than me on this topic will comment.
 

Eljefegeneo

Still trying to learn
Local time
Yesterday, 19:46
Joined
Jan 10, 2011
Messages
904
Yes, I did. I use late binding because I originally had a problem with two different versions of Office on a computer. Access 2010 and the rest Office 2019. So there are no references missing because both have the same four references. Thanks for checking on this point, but it isn't the cause of the problem.
 

Pat Hartman

Super Moderator
Staff member
Local time
Yesterday, 22:46
Joined
Feb 19, 2002
Messages
43,233
why does not simply sorting by the date field get the days in order?
 

The_Doc_Man

Immoderate Moderator
Staff member
Local time
Yesterday, 21:46
Joined
Feb 28, 2001
Messages
27,148
Darn, Pat, you beat me to that one. Last I looked, if you want Sunday before Monday, just sort by date. If you ONLY sort by Weekday (which IS after all possible) then you will get ALL Sundays before you get any Mondays. Did I miss reading something or is the desired sort more complex than this?
 

Eljefegeneo

Still trying to learn
Local time
Yesterday, 19:46
Joined
Jan 10, 2011
Messages
904
OK, the Day1 field is text, a three letter abbreviation for the days in a week. Sun, Mon, Tue, Wed, Thu, Fri, Sat. Seven days. My original query where I used the code in Post #1 worked fine in Access 2010 but didn't work in Access 2019. The query from Isaac in Post #8 works in Access 2019 without the rest of the fields in my original query. To a layman like me with limited knowledge of coding, it would seem that there is a unknown difference between the 2010 and 2019 versions. So I opted for the simplistic approach as explained in Post #19. But it is "hagame loco" trying to figure out why the original query didn't work in the 2019 version when the change in the DaySort made it whole again.

But then it is solved, more than one way to solve a problem and if it works, who is to say my version is not better.

Thanks for all your help.
 

Isaac

Lifelong Learner
Local time
Yesterday, 19:46
Joined
Mar 14, 2017
Messages
8,777
But it is "hagame loco" trying to figure out why the original query didn't work in the 2019 version when the change in the DaySort made it whole again.
I agree in that your persistence in trying to troubleshoot the original "working in 2010, not in 2019" was very legitimate. Because it is frustrating when the same thing works in one environment and not in another. And, as you saw from the responses, pretty hard to troubleshoot sometimes.
But I am glad you got something that works for you at least. Best of luck with your project!
 

Users who are viewing this thread

Top Bottom