Howdy, did a quick search and couldnt really find much like my problems, so here goes:

99 foreman 400, has been backfiring a lot as of late, took the dump screw out of the spark arrestor and revved it up, blew a lot of junk out. Seemed to help.
Battery keeps draining, wont hold a charge for more than a day or two even while sitting and not running, battery is new and checks out good. Here of late when you start it (after charging) it runs rough as heck, almost like a timing issue, bogs down when you give it gas and dies. Had a buddy come by the other day and while it was doing this he hit the light switch to on and it idled perfectly and you could rev it up, did this for about 5 minutes and then it just died. Checked for spark, and sometimes we would get one and sometimes not, checked the coil and its good.
All fuses are good and carb is cleaned. Where do I go from here????

__________________
98% percent of people in the country say oh shit when they hit ice, the other 2% are from Maine and say hold my drink and watch this!
Teddy Roosevelt once said "if you live in america learn to speak english and be american"

I was thinking a dead short somewhere (at least causing the battery to drain) But when he hit the headlight switch to on and it ran great, Im now thinking something else that could tie it all in together, battery, rough idle, missparking???? Just fairly ignorant and dont have a good manual yet (its on the way, I live in the boonies) Could it be the CDI?

you got a good spark plug? could be a short, im not an expert, sounds like there is a bunch of problems.

__________________
98% percent of people in the country say oh shit when they hit ice, the other 2% are from Maine and say hold my drink and watch this!
Teddy Roosevelt once said "if you live in america learn to speak english and be american"

My guess is a bad or shorted regulator/rectifier. Try charging your battery up to a full charge and put it back in and test the voltage of the battery with the engine running. Start the engine and turn the headlight on. Now, use a voltmeter to test the battery voltage. The voltage should be 14.7-15.5 volts at 5,000 RPM. If it tests out of spec, do the regulator/rectifier test as shown below.

__________________Most 4-wheeler problems are caused by a loose nut connecting the handlebars and the seat!!

You only need two tools in life -- WD-40 and duct tape. If it doesn't move and should, use the WD-40. If it shouldn't move and does, use the duct tape.

as helmut said..could be your reg/rec not charging your battery..buttttt..keep in mind..if your c.d.i or stator is bad..this will cause you to have elec issues too !..soo..check all of your wires..reg/rec..battery for a dead cell ?..stator..to see if it's putting out enough voltage ?..soo much comes into play when it comes to making a atv engine run. if you don't have the right voltage...air..spark..fuel..compression...it won't run right at all..if one thing is out of adjustment..this will cause a chain reaction.

Battery is practically brand new. In fact its the second one I got, the first one I purchased wouldnt take a charge at all, so the parts store charged this one up and exchanged it for me. Took it back in and they tested it fine.