If you do not need the decimals, then a 100% working solution would be:
- Remove your current custom price format modification
- Install the “Currenct Format” module.
- Setup the “Currenct Format” module in the proper way (hide the decimals, set the needed thousands separator, etc.)
So the total solution price will be $199 + $150.
Also the “Currenct Format” module would overcome your current custom price format modification, so maybe you do not need the step 1, but I do not know it. You can just install the “Currenct Format” module yourself and check it.