He only went a short period of time, starting in October 1863. An old book on Oxford says that he was summoned back to Denmark upon his father's ascension to the throne and the subsequent war with Prussia. The first happened in November 1863, the 2nd a few months later. When exactly Frederick returned, I don't know. There's apparently a stained glass window at Christ Church Hall commemorating the attendance of Edward VII and Frederick VIII.