If you've replaced the power adapter and the battery, it's the small jack that the power cord plugs into that's bad. Sometimes they break off of the motherboarfd because the manufacturer uses cold solder joints. You'll have to replace this power jack and re-solder it to the motherboard.
Sometimes they hide screws under the keyboard, under the hard drive bay, memory bay, etc...check for those first.