I had a really useful link to the Windows console API. Apparently this information is going to disappear into the archives with the advent of Vista. My link is now worthless.
I'm going to give you this
link. It may disappear tomorrow, or you may have to chase the links that appear to address your problem. If you are not successful in accomplishing this, post back. I will give you some code that deals directly with this issue. You can then search Microsoft or MSDN using specific function names. If support for all this disappears, I don't know what to tell you. Frankly, this lack of support, which is not uncharacteristic of Microsoft, still pisses me off substantially.