Usually the problem is the reverse and people usually have to pay a sales or use tax when they register a car purchased in a state that doesn't have a sales tax.
Wyoming isn't going to make any effort to help you avoid paying sales tax and unless there's some exception in the law, you may wind up paying WY tax. And Montana sure isn't going to care when you register the car.
The dealer should know if there's a way around this.
People buying cars in California seem to run into the problem a lot too, and wind up getting double taxed sometimes.
Washington State used to let retailers sell stuff tax free to citizens of Oregon and Alaska (states without sales taxes) but I think that practice has ended.
Another thing to consider is that most state lemon laws don't apply to new cars purchased in another state.
I'd call or email the Wyoming DMV or Department of Revenue and ask them if the sales tax is avoidable.