void DisplayWelcomeMessage(bool displayOnlyInfoButton = false) { TextsModel texts; if (Conf.Instance.Model != null) { texts = Conf.Instance.Model.AppConfig.Texts; } else { texts = new TextsModel(); texts.WelcomeMessage = "welcome"; texts.BtnMore = "more"; texts.BtnNext = "next"; } MessageButtonClicked button2Click = null; string button2Text = null; if (Conf.Instance.ElectionsStarted()) { button2Text = texts.BtnNext; button2Click = () => { Dispatcher.BeginInvoke(() => { HideMessage(); InitializeBarcodeReader(); StartScanning(); }); }; } ShowMessage(texts.WelcomeMessage, texts.BtnMore, () => { var timer = new System.Threading.Timer(obj => { Dispatcher.BeginInvoke( () => { NavigationService.Navigate(new Uri(App.XamlFolder + "InfoPage.xaml", UriKind.Relative)); }); }, null, 200, System.Threading.Timeout.Infinite); }, button2Text, button2Click, MessageType.Regular); }