Chevy 2003 Trail Blazer ls

GM tech = mw
question = When i turn on my a/c and let it idle the rpm dips way below 1
and almost shuts off until i rev it up again but if i let it sit there it shuts off, it
does the same thing when i turn on the heat, other than that the engine is
fine, but only when the a/c and heat get turned on it starts to die, i just
changed out my battery as well so i have a new battery, also with that my
power buttons on my door don't work from time to time, and i wonder if they
are related to each other.
OK. This is a very common problem when there is carbon buildup in the throttle body
bore and plate.

Suggest a good cleaning. The throttle body is the front top of engine that the air
cleaner duct hooks up to.

Remove the duct, open the throttle blade, spray some carburetor or carcon cleaner
from any parts stor all around the bore and plate.
Then spray some on a rag- not a paper towel, and wipe all around the bore and plate.
Re-install duct and start the engine. It will run rough for a few second. Rev it up a few
times to "Clear it out".
Then take for a short ride doing a few hard accelerations.
Shut truck off for 2-3 minutes, then start ans let idle.
After this, the idle should be fine."

The window problem may be in the switch itself. If this is the problem, a new switch
would need to be programmed after replacement.
Auto Repair Help by Expert Mechanics