Up until yesterday (with Snow Leopard), closing the lid would cause my MacBook to sleep whether or not the external monitor was connected.
Since upgrading to Lion last night, closing the lid when the external monitor is attached just tosses all windows to that screen and keeps going.
I realize I can sleep via the Apple menu or keyboard before closing the lid. I'd rather not have to, and I'm wondering if there's a setting to restore the sleep-on-close behavior.
Finally fixed it!! After reading so many pages including this thead, I went into print and scan features unchecked the "share printer over network option"! It worked!!!