Until 1798 , he studied in Dresden before settling in Copenhagen . He studied in Dresden until 1798 , before settling in Copenhagen . He studied in Copenhagen until 1798 , before settling in Dresden .