View Single Post
 
Old 10-08-2023, 03:22 AM
Guessed's Avatar
Guessed Guessed is offline Windows 10 Office 2016
Expert
 
Join Date: Mar 2010
Location: Canberra/Melbourne Australia
Posts: 4,162
Guessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant future
Default

I think the issue is on the mins line. That is one line that I didn't check on your provided code and it appears to start from the wrong spot. Change the 4 to 3 eg
Code:
mins = CInt(Mid(aRng.Text, 3, 2))
You can debug these things yourself by stepping through the code and hovering over the variables after the line has executed to see what value they have.
__________________
Andrew Lockton
Chrysalis Design, Melbourne Australia
Reply With Quote