private void GoTo(Abtlinks announcements) { switch (announcements) { case Abtlinks.NewsArchive: while (SeleniumDriver.Instance.Title.Equals("Home")) { try { action.MoveToElement(NewsLink).Perform(); action.MoveToElement(Announcements).Perform(); NewsArchiveLink.Click(); } catch { } } Console.WriteLine("Clicking on AGI Top Navigation ->News->News Archive"); Console.WriteLine("</br>"); break; case Abtlinks.Events: while (SeleniumDriver.Instance.Title.Equals("Home")) { try { action.MoveToElement(NewsLink).Perform(); action.MoveToElement(Announcements).Perform(); EventsLink.Click(); } catch { } } Console.WriteLine("Clicking on AGI Top Navigation ->News->Events"); Console.WriteLine("</br>"); break; case Abtlinks.Announcements: while (SeleniumDriver.Instance.Title.Equals("Home")) { try { action.MoveToElement(NewsLink).Perform(); Announcements.Click(); } catch { } } Console.WriteLine("Clicking on AGI Top Navigation ->News->Announcements"); Console.WriteLine("</br>"); break; } }