What you are describing is more likely a "reverse sneeze." Most of the time, a reverse sneeze is not considered to be a problem and will usually correct itself within a few moments. There can be medical reasons for this type of behavior, such as allergies or mites in the upper respiratory tract but, most of the time, a cause will never be established.
I am enclosing a web site reference for further reading:
As you can see from this article, something as simple as excitement can cause a reverse sneeze. Whether or not your dog's reverse sneezing was related to the vet visit might not ever be known.
NOTICE: The information provided on this site is not a substitute for professional medical advice,
diagnosis, or treatment. Never delay or disregard seeking professional medical advice from your
physician or other qualified health provider because of something you have read on Wellsphere.
If you have a medical emergency, call your doctor or 911 immediately.