Hysterosalpingogram - advice

C
Does anybody have any experience with these? If so, how long after starting TTC did you get one? My doctor recommended I get one. It sounds like they can be very painful and invasivene.