Question: May one begin walking towards the end of Shabbat to a store (outside of Israel) so that one may enter the store immediately at the conclusion of Shabbat in order to purchase something?
Answer: The prophet Yeshaya (58, 13) states: “If you shall turn away your foot because of the Shabbat, (and abstain) from pursuing your business on my holy day etc. then shall you delight yourself in Hashem etc. for the mouth of Hashem has spoken.”
Our Sages have taught in Masechet Shabbat (113a) and Masechet Eruvin (38b) that “turning away one’s foot because of Shabbat” refers to not walking on Shabbat the same way one would during the rest of the week and “pursuing your business” refers to the fact that one should not stroll around the edges of one’s field on Shabbat in order to ascertain what it requires following Shabbat, such as ploughing or watering.
The verse concludes, “For the mouth of Hashem has spoken,” meaning that this law that one may not walk in his field on Shabbat is not an enactment of the Sages; rather, it is an actual prohibition told by Hashem to Moshe Rabbeinu on Mount Sinai. For generations it had been a “law transmitted orally to Moshe at Mount Sinai” until the prophet Yeshaya recorded it in writing explicitly. (Chazon Ovadia-Shabbat, Part 6, page 1)
Based on the above, one may not walk to and then stand in front of any given store on Shabbat in order to purchase something immediately after Shabbat. Even if one is not carrying any money with which to purchase the item, it is nevertheless forbidden, for by standing near the store, it is clear that one is doing so in order to be able to enter the store immediately following Shabbat and purchasing anything on Shabbat is forbidden. Only once Shabbat has concluded may one walk anywhere or perform any transaction he wishes.
We must add though that if one intends to purchase something for the purpose of a Mitzvah, such as in preparation for a wedding and the like, one may prepare himself on Shabbat in order to purchase the item after Shabbat, for the verse states, “From pursuing your business on my holy day,” meaning that it is only prohibited to pursue one’s personal business on this day, however, it is permissible to pursue “Heavenly business,” i.e. a Mitzvah purpose, on this day.