1. You do not have a realistic timeline.
Yes, really. Let's put it like this, if you have been gaining weight and have been on and off the diet train for the past 10 years, do you think you are going to be able to lose a ton of weight in two weeks? Probably not. I would estimate that MINIMUM your years can look like months in "recovery". So continuing with the example from above, if you spent the 10 years causing havoc on your body, you can expect it to take about 10 months to reverse out of the place you had your body and actually start to see the transformation you want to see.
2. You aren't being consistent enough.
Listen, yes you can and should still enjoy treats and other foods while you are in a diet phase but you need to remember that those extra calories really add up. While you are trying to hit a specific goal, stick closer to the 90/10 rule. 90% of the time you on right on with your diet and only 10% you are having other foods. Once you are closer to your goals, you can switch over to the 80/20 rules.