There's an incantation to recalibrate the auto-up on the windows. I had to do it after replacing the battery. The key step is to hold the switch in the close position for a few seconds after the window is fully closed. You will hear an audible click.
See post #6
here.
Note that the windows are programmed to go back down if they hit the slightest resistance, so you don't accidentally strangle your dog.
It sometimes takes me 2-3 tries to get the passenger side closed. It rubs a little about 2/3 of the way up and often reverses.