There are only a very few things that can cause this problem.
I will list them for you.
1. A chain that is too loose. The chain must be tight and you cannot have ANY chain slop at all.
2. The chain is damaged where it goes into the bar. Once a chain has been thrown off, it usually damaged the drive links and it will not stay on.
3. The sprocket at the end of the bar may be damaged or is not rotaqting properly. you may have to replace the bar.
4. The chain may be the WRONG one. Many times a customer goes to a discount store and buys a chain that is not the right one. There are many different chains. You MUST get the EXACT one for your saw. There are different pitch's. guages' link counts, etc. In fact, just for an example, I have over 15 different 16" chains. And they CANNOT be interchanged .
5. The oilier may not be putting out enough oil or you may not be using good bar oil. (THis is not usually a big problem with chains coming off but it has happened on ocassion.
6. The sprocket on the Chainsaw itself may be worn. There should be NO wear maarks on the sprocket AT ALL. Many times these get worn and they actually have worn a groove in the sprocket. This will cause chain damage as well as throw off the chain.
Hre are some tips to install and tighten a chain.
First, make sure that the chain is on correctly.
Then loosen the bar bolts a little,
Then lift up on the bar with one hand and keep it lifted up .
While the bar is lifter up, tighten the chain with the adjusting screw.
Continue to lift up on the bar .
Then while it is still lifted up, tighten the bar bolts to tighten the bar.
Do NOT release the bar from being lifted up until the bar nuts are COPLETELY tight.
If this procudure is NOT followed, then when you start to use the saw, the bar will move up and losten the chain and the chain can come off.