If someone is invited to eat on motzai Yom Kippur with friends, but has to take medication after the fast, may he carry the medication to shul in the morning to take after the fast, or is this hachanah mekodesh lechol? G’mar chatimah tovah.
ב"ה Shalom and and Gmar chatimah tovah. Since you are already aware of this situation now, the simplest solution would be to place the medication in Shul or by your friends prior to Yom Kippur, this way your medication is available and you don't run into any questions. A second possibility is, if you may need the medication on Yom Kippur( in a way that it is permissible to swallow it on Yom Kippur) since the medication is needed also on Yom Kippur, it wouldn't be considered "Hachana=preparation) and you may take it with you where it is permitted by Eruv, even if you need it also after Yom Kippur. (Shemirat Shabbat Kehilchata Chapter 28:78) It is possible that we can compare this situation to what Rav Shlomo Zalman Oirbach zt"l ruled (Shemirat Shabbat Kehilchata Chapter 28:89) that an action which is allowed on Shabbat (because it is not considered a melacha or an Issue d'rabanan) and it acquires no special effort and people do it without giving thought to the benefit of doing it , may be done on Shabbat even if there is benefit for the weekday, as long as the person doesn’t express it explicitly that it is being done for the weekday. Based upon this ruling, a person would be allowed to take a sweater (by hand) on Shabbat afternoon (where there's an eruv ) even when it's hot so that it can be worn in the evening. Similarly a person can take the house keys with him when going to Ma'ariv Motzei Shabbat so that the house can be open after Shabbat. Likewise, it seems you would be able to take medication with you, since it acquires no effort and you probably do it during the week as well without giving it much thought other than tossing it into a pocket or pocketbook. All the best