Arduino lights up but doesn't execute its code or gets recognised by computer

My arduino lights up when i connect it to my computer, But it does not execute its code, or no code gets uploaded to it because arduino ide doesn't recognize an arduino..

I have an arduino uno by Sainsmart

Also, the tx and rx lights don't go off...

Please help :frowning: :frowning:

Thanks in advance!

Do you have a good USB cable, not a power-only cable?
Try the loopback test to start, see if the 16U2 is properly programmed to start,

If not, you'll need to get your hands on a Programmer, or an Uno that can be loaded with a Programmer sketch,

The cable seems all right.. I'll do the loopback test and post the results..
Thanks!