@D**
I think it is the regular TM7 form, although there may be an additional form on top. Then you need something filled out by the doctor certifying you cannot travel, and photos of you preferably showing why you cannot travel.
I also needed to sign power of attorney sending someone else in to immigration. If you go into immigration yourself they may take the view you can travel.
You can try, but I'm not sure you will get this for outpatient dental treatment. My understanding is that medical extensions are more for emergencies that mean you really CANNOT travel.
There is a medical visa (MT) for procedures, but that is something you get before you come to Thailand for treatment, rather than as an extension.