This step by step tutorial guide will show you how to program your Xfinity/Comcast Cable TV remote control for your Television (TV). Will also provide you with a list of TV Codes you can look up to match your TV Manufacturer, Brand Name and Model 
i have XFINITY cable at home and i just got a new Samsung Big Screen TV. if you need to know how to re-program my remote control for the new tv, you can follow this short tutorial. i will show you how easy it is.
1. First step is to be sure you have your TV turned on.
2. If you already know your TV Code, Skip this step. Download the file attached to this post. if you can't download this file, an alternative is to look at the manual that came with your remote control, it will list the codes.
3. OK, now that you have the TV Code, On the Xfinity remote control, Press and Release the TV key at the top of the remote. you will see a red light on the tv button when you press it.
4. Now, Press and hold in the SETUP key on the remote control, press the key until the TV key flashes two times, after it flashes twice, you can release the SETUP key.
5. now you are ready to enter the TV code. Enter the TV Code, if you have entered a correct code, you will see the TV button on the remote control flash two times if you entered the TV code correctly.
NOTE: if you have a TV Code thats only 4 digits, try putting a one at the beginning.. for example, if my tv code is 1234, try entering 11234.
6. If the TV Button on the remote control flashed two times, it means that the code was accepted, otherwise, re-do the steps again starting from step 1.
7. Now test to see if the code you programmed your remote control is the correct for your TV.. Hold the control aiming toward your TV then press the Power button on the remote. If your TV does turn ON, You are done. If it does not, it means that the code you entered is not the correct one for your TV, try another one. and restart from step 1.
THANKS. if it worked for you, i would appreciate if you leave your comments by telling us what code worked for you and what brand is your Television.
UPDATE: thanks for all your comments. after reading some comments, if the above codes do not work on your TV, try adding a 1 at the beginning of it.
example: 0030 = 10030
Thanks to Kevin and Jon.
if for some reason your tv doesnt work, please reply with your comments with the make and model of your television set so we can look up the codes for you.
Model: R87 high definition LCD TV
Date Purchase: September 6, 2011
Location: Los Angeles, California