M.P.
I know it's really difficult at times to not yell but it's important to work on keeping a calm reasonable voice. I grew up with yelling parents and am a yeller myself and so I know how difficult it is. She is most likely responding to your tone of voice. It says to her that you don't like her. I know your tone is because you don't like what she's doing. It might help to talk about that with her. Apologize for yelling and tell her you're working on not yelling; that you yell because you're frustrated with how she's acting. Emphasize how much you love her.
I think that once your recognize that yelling is not working, as you seem to have done here, that you'll find a way to remain calm.
I discovered after months of frustration that often all it took to get compliance is to stand mute and wait for my grand kids to do what I asked. I did usually have to restrain them. i.e. keep them from running away when my goal was getting them into the seat. This does mean having to start earlier in situations such as leaving and being more concerned with my grandchild's feelings than with being on time or getting the dishes done, etc.
It helps me to keep in mind my wish to treat them in as respectful way as I'd treat anyone else. I was a supervisor and knew that I could not gain compliance by showing my frustration. Same with children.
I also learned that when I started to feel the need to yell I stopped what I was doing and tried something else. I just stood, mute while I thought about what to try next. Often my grandchild complied while I was thinking. Sometimes silence is heard better than yells.
I tried using bribes along the way. If you get in the car now we'll stop for ice cream. Didn't work. Perhaps you can tell, getting into the car and fastening the seat belt was a big one for us. lol I discovered that my granddaughter needed some decompression time between preschool and home. So I got in the car with her, in the front seat, and held her for 10 or so minutes. We talked about whatever she wanted to talk about. I introduced stickers as a sometimes part of that time. I would say, as soon as we get your seat belt fastened I can give you your sticker. This may seem like a reward but there is a subtle difference. She would get that sticker anyway. It was already hers. She just needed to get her seat belt fastened first.
Doing things in order is similar. She wants to play but you want her to finish dinner. As soon as you take 3 more bites you can get down and play. As soon as you get into your pj's I'll read you a story.
I found it also helped to ask for her help by saying, I have to get to the store in 10 minutes. Will you help me get there fast? Let's count while I drive. Can we get there by the time we reach 20? Or while at the store she wants out of the cart and keep grabbing at the shelves. I'm looking for your favorite cereal. Will you help me find it? And then describe it. Give colors, describe package. Keep her involved.
Or perhaps sing with her. I usually took along a couple of toys or books to keep them occupied. When they were 2, I'd fold a blanket for a cushion and have them sit in the food part of the cart.
When wanting her to leave I'd have a race with her. I'm going to get to the car first. When they were older we would have a race to see who got their seat belt fastened first. Sometimes I gave them as many pennies as their age when they "beat" me which of course they nearly always did. lol
At 2 you can Hold her hand and say let's run. Turn everything that you can into a fun game. I actually think I play more as an adult than I did as a child. My parents were so serious and I was shy, scared, and obedient.
I don't ever try to talk when they are yelling/fighting. It's like arguing with a drunk from my adult experience. No one wins. Wait until they stop, which they will when they realize that you won't argue/fight.
When they would unfasten their seat belt, I would pull to the side of the road, tell them to fasten it again and then wait. I don't think I ever had to wait more than 5 minutes. They could not stand my silence.
I also had to learn to choose my battles. You don't want your diaper changed. OK, we won't change it. When they got uncomfortable they asked to be changed or they got whiny and were glad that I sympathized with how uncomfortable they were and let me change it. I didn't fight about changing clothes either. Dirty clothes just aren't that important. Some nights we didn't have a bath. Another good thing to have but not necessary. My theory is that kids respond to my ability to be flexible. If I once in awhile let go of my need to have them clean in clean clothes, for example, they were more willing to comply most of the time. I'd sometimes remind them of it. I let you stay in your dirty clothes yesterday but today we really do have to have on clean clothes.
My daughter allows her kids to sleep in their clothes if they don't want to put on their pjs. I'm a bit more willing to work on getting them changed. That's my preference. Back to the, I'll read you a story once you're in bed with your pjs on. And then wait them out. Didn't/doesn't always work. So, I bet I can get my pjs on quicker than you can might. Or, OK you can wear your clothes but you cannot get on your bed, said in a joking way. Then leave the room. No story. I'd come back in a few minutes and we might have a compromise. I'd help them get them on. lol
The idea is to make them think it's their idea. Fun and games often work when a serious request doesn't. Respect for them, which means not yelling, also helps.
When I was in training to be a supervisor I was told that if it came to the point that I had to use "I'm the boss" attitude or words, I'd already lost. No one, not even a baby/child want to feel that they have no choices. Not complying is always a choice. Also, there is always a consequence, positive or negative, for all choices. Lots of praise works really well no matter the age. Silence and a look of disapproval also works. A look of disapproval is more easily tied to the action in a person/child's mind then an angry voice.
Time outs and taking things away have never worked with my grandkids. They didn't work with my daughter either. So, I quit trying to use them. I gradually learned how to apply natural consequences. Now, taking a toy away when a child throws it is a natural consequence. Not giving it back until they're calm and not likely to throw it again is a natural consequence. But taking a favorite toy away because they wouldn't get in the car is not natural and just doesn't usually work.
An unexpected bonus for not yelling most of the time is that when I did yell they paid more attention to me. We would have a cuddle time afterwards when they'd done as asked and I'd calmed down. I would apologize.