I believe they have the same active ingredient so it would work just as well. Repeating the treatment every two weeks is important as this only kills the adult worms, not the eggs.
in the future, my be good to invest in a quarantine tank. I like mine to be 10 gallons so it’s cheaper medication wise. I deworm all fish before they go in my display tanks 😊