This advice actually comes less from a certainty that whatever they're suggesting will work, than from a certainty that whatever you're doing won't work. About half of all Americans are trying to lose weight at any given time, so any given person is likely to have tried a bunch of different methods, which apparently don't work, otherwise they wouldn't keep trying. It takes an incredible amount of discipline to actually lose weight and keep it off, and most people have trouble accepting how much work they'd have to put in, so when they fail, they blame the method and move on to a new one.
Like the Taco Bell diet. Reasoning: It tastes terrible, so it must be good for you!
Because it can't be because weight loss is really hard. It must be because they just haven't found the right diet yet. This next one must be the right one! And if you, their poor sap of a friend, are trying one of the methods they've already tried and failed at, you're clearly barking up the wrong tree, and they've got to stop you for your own sake.
"Stay off the court, Rick, you are just wasting your time with cardio."