It's easy to say but this is the hardest thing to do. Especially for most people in this generation are not that close to their parents which makes it hard to talk about things like that. I know someone, younger than me who is close to the said situation. His parents can't do anything or any approach, they can't stop that kid from gambling. The thing is this kid was influenced by his friends and through social media. He sees that it is being promoted, so what's on his mind is it is okay to do gambling.
It's easy to say but it requires one step done continuously. In your case, the parents can ask for help from other people outside the family circle or who are still related to the family. By asking for help, the person can approach their child and talk personally.
Maybe the child feels embarrassed to speak frankly to his parents. So, with help from outsiders, he can talk frankly with that person so his parents can understand the real problem. Openness is needed from the child so that parents can understand what makes their child influenced by their friends.
After finding the root of the problem, they can find a solution so that their child can stop gambling and not be influenced by his friends. Children who grow up in this era cannot be approached using old methods because they have been influenced by technology and others. Parents must learn to find the right way to approach their children so that their children can talk and be honest with them. And it takes time so parents must be patient and continue to approach and accompany their children.