The whining continues. Another technique, give him a choice. You have a choice, either schoolwork first or there will be no program time. The whining continues. He certainly is persistent, you might think.
Negative thoughts create negative feelings and situations.
You're about to lose your patience. You try again, quite a bit firmer. It doesn't let up. You might be at your wits end and just lose it. I've been known to lose it, not that I want to, but sometimes my boys' tenacity gets the best of me.