We don't use the article before numbers. But it's possible to say etthundra if you want to stress that it is one hundred as opposed to two hundred or something. However ett in that word is always ett and it doesn't agree with år but with hundra.
There's a colloquial expression with 'en' before numbers that means 'approximately', 'about'.
So it is possible to say Hon har sovit i en hundra år, but that means 'She's slept for about 100 years'.
We use på for durations where something is expected not to have happened. For instance: jag har inte ätit på tre timmar = I haven't eaten in three hours. To contrast, jag har inte ätit i tre timmar would mean you haven't spent the past three hours eating, but you may have eaten at some point during that time.
Unlike other languages that do not need an article, English requires either a or one before the numbers hundred, thousand, million, billion, etc. Saying a hundred is much more common, and can be used in cases of rounding (i.e. she actually slept for 99 years or maybe for 102 years), whereas if you say one hundred, you are being either more precise or more formal. It was exactly 100 years, or you are at a fancy dinner party.