[C:1](OC(=O)C)(=O)C.Cl.[CH3:9][NH:10][CH3:11].C=O.[C:14]([C:17]1[CH:18]=[N:19][N:20]2[CH2:25][CH2:24][CH2:23][CH2:22][C:21]=12)(=[O:16])[CH3:15].C(=O)([O-])[O-].[K+].[K+]>>[CH3:9][N:10]([CH2:1][CH2:15][C:14]([C:17]1[CH:18]=[N:19][N:20]2[CH2:25][CH2:24][CH2:23][CH2:22][C:21]=12)=[O:16])[CH3:11]Acetic anhydride (4.3 g) was dropwise added while stirring dimethylamine hydrochloride (1.0 g) and 37% formaldehyde solution (1.0 g) at 50° C. After the dropwise addition, the reaction mixture was stirred at 80° C. for 1 hour, and 3-acetyl-4,5,6,7-tetrahydropyrazolo[2,3-a]pyridine (1.4 g) was added. The mixture was stirred for 2 hours with heating. The reaction mixture was poured into ice water and potassium carbonate was added, which was followed by extraction with chloroform. The extract was dried over magnesium sulfate and the solution was evaporated under reduced pressure to give 1.75 g of 3-(3-(N,N-dimethylamino)propionyl)-4,5,6,7-tetrahydropyrazolo[2,3-a]pyridine. This compound (1.75 g) was dissolved in acetone (10 ml) and methyl iodide (1.1 g) was added. The precipitated crystals were collected by filtration to give 1.2 g of a quaternary salt of (3-(4,5,6,7-tetrahydropyrazolo[2,3-a]pyridin-3-yl)-3-oxypropyl)trimethylammonium iodide, m.p. 210-213° C.