Did you charge the battery for several hours before first turning it on? If you don't this will cause problems. Another possibility is that you have a defective battery. Changing the battery on a One XL is pretty simple, so hopefully you didn't damage anything inside. Did you double-check to make sure the battery is properly plugged in to the main board?