The basic idea is that if you're wanting to fill a UI element, or highlight items in a UI element, then it's best to do so in either OnWindowLoaded() or OnInitWindow(), rather than handling it after all initiation has occurred.  This is because OnInitWindow() in the base class sets up animations and the like, which can be conditionally dependent on content.

I would move the UpdateConnectionList() call to OnInitWindow() before you call the baseclass.  The rest of the stuff here can be done before CGUIDialog::OnMessage() is called I think?