Disclosed is the use of a heterocyclic compound of formula (I), wherein the substituents are as described within the specification, in the manufacture of a medicament for treatment by inhibiting amyloid beta deposition, amyloidosis, cerebral amyloid angiopathy, cataract, glaucoma, the progression of glaucoma age-related macular degeneration, rheumatism, osteoporosis, metabolic syndrome, wrinkles, and hair loss.