I try to remember to put the number of days in the "Course" box for antibiotics, usually 1 day more than the actual duration of the antibiotics, and they will automatically become inactive after those days.
I will also try to do it for time limited medication courses (like prednisone taper, oral or topical medications for rashes, etc)