M.M.
We go through this with my son who is 2.5. He is fine with anyone else but me. It is so hard in public places.
What helped me was taking him out on "test" trips (when I don't absolutely need to buy groceries, etc.). We did this over and over one weekend - Went to the supermarket, CVS, the mall, etc. I took him out and told him he had to ride in the cart/stroller. I told him if he screamed to be held or tried to climb out of the cart/stroller, we would leave immediately (I think we did one or two warnings). And we did leave and go home. If we actually needed to buy something I would make sure my husband came for the trip too so one of us could take my son immediately to the car if he screamed to be held or tried to climb out of the cart. I didn't yell at him. I just said calmly, "you are not sitting in the cart so we are leaving", and carried him out without saying another word to him or making eye contact. I didn't carry him in the normal way like he wanted to be held; I carried him either over my shoulder or under my arm so he didn't feel like he was getting what he wanted.
There were a couple times I had to wait out a tantrum in the back seat to get him into his car seat. I just let him scream and writhe around in the backseat, not talking to him, reminding him calmly every couple minutes that we couldn't go anywhere until he got in his car seat and stopped screaming. Eventually he gave up.
It really only took three or four trips like this (in a row) for him to get that I was serious about where he needed to sit. During this training period I did *not* give in at all. You have to let him know you are serious. If you can spare a weekend for this kind of training, it might help. I see you are in the city and you might need to adapt this plan to fit your situation, but something similar might work. Maybe just take him around the block over and over -- so you are close enough to home to carry him straight there. Good luck!