2H-1, 4-benzoxazine can be generated in situ from 1-(o-aminophenoxy)-2, 2′- dimethoxyethane in trifluoroacetic acid whence further reaction leads to the benzoxazine bye 7. The benzothiazine dye 9 can be derived in similar fashion from 1-(o-aminophenylthio)- 2, 2-diethoxyethane.