That took me a while. Lovely DB, but very complicated to be as good as it is.
I would probably approach it this way.
In modCalendarCode and sub ShowMonthAppts I would add code to add the end time just as the start time is being added to vSubject. ?
To do that, you will need to create another TempVar to hold the choice of showing EndTime. That way it will keep it's flexibility.
the code I am talking about is here
Code:
If TempVars("tmpShowStart") = True Then vSubject = Format(rst!ApptStart, " h:nn ") 'if ShowStart = True then add Start Time only
If TempVars("tmpShowStartEnd") = True Then vSubject = Format(rst!ApptStart, " h:nn-") & Format(rst!ApptEnd, "h:nn ") 'if TempVars("tmpShowStart")End = True then add Start Time & End Time to vSubject
If TempVars("tmpShowSubject") = True Then vSubject = vSubject & rst!ApptSubject 'if TempVars("tmpShowSubject") = True then add Subject field to vSubject
If TempVars("tmpShowLocation") = True Then vSubject = vSubject & " " & rst!ApptLocation 'if TempVars("tmpShowLocation") = True then add Location field to vSubject
I had to comment out a fair bit of code due to my Access being so old and not having those properties
Tempvars are set in InitialiseDefaults and they get their values from tblCalendarSettings, so you will need to add a new field in that table and amend code to suit.
Where did you get this, as I know someone who was looking for something like this.?
HTH
Edit: And after doing all that and just reviewing the post, I can see that the author did that already. You just need to amend the settings in the form CalendarSettings and tick show start and end times.
Not to worry, as it was a learning experience for me and this DB will help someone else.