It is prepared in two different ways, both starting from 6-methyl-8-methanesulfonyloxymethylergolin (II), m.p. 192-4 C, prepared by reaction of the corresponding hydroxy compound (I) with methanesulfonyl chloride in pyridine: 1) The starting product (II) is first chlorinated with N-chlorosuccinimide (A) in dioxane to 2-chloro-6-methyl-8-methanesulfonyloxymethylergolin (III), which is then treated with sodium cyanide in DMSO. 2) The starting product (II) is first treated with sodium cyanide in DMSO to give 6-methyl-8-cyanomethylergolin (IV), which is then chlorinated with N-chlorosuccinimide (A) in dioxane.