Taking a 2 year old to the store..Advice?

Amanda
Hello, I have a wonderful little 2 year old boy name Mason, who has tons of energy and does not always like to sit still. He usually does great with listening at home but some days are his way or no way lol. Well when we go to the grocery store or like Wal-Mart Mason does not like to sit in the buggy, he will throw a HUGE fit, scream and cry until he gets his way which is just walking around. I don't always like him walking around because he tends to want to take off and go do his own thing instead of standing next to Momma and Daddy. Sometimes bribing his with candy or something I know he will be happy with works but only for a short time. Advice as to what I can do to get him to listen to me and sit in the buggy when we go to the store?