public static bool GetTableRowDataForImportLabDictionaryErrors(List <ImportLabDictErrorData> errorData)
        {
            BrowserUtilities.DS_SwitchToFrame();
            try
            {
                foreach (ImportLabDictErrorData data in errorData)

                {
                    WebTable_SearchCriteriaItemList list = new WebTable_SearchCriteriaItemList();
                    list.AddSearchItem(new WebTable_SearchCriteriaItem(0, data.WorkSheet, TableColumnContentType.Text));
                    list.AddSearchItem(new WebTable_SearchCriteriaItem(1, data.Row, TableColumnContentType.Text));
                    list.AddSearchItem(new WebTable_SearchCriteriaItem(2, data.Column, TableColumnContentType.Text));
                    list.AddSearchItem(new WebTable_SearchCriteriaItem(3, data.Error, TableColumnContentType.Text));
                    if (list.List.Count > 0)
                    {
                        IControl tableRow = WebTableUtilities.Table_FindRow(ImportLabDictionaryPage.ErrorTable, list);
                        if (Control_PropertyUtilities.IsControlNull(tableRow))
                        {
                            Utilities.BrowserUtilities.SwitchToWindow();
                            return(false);
                        }
                    }
                }
                BrowserUtilities.SwitchToWindow();
                return(true);
            }
            catch (Exception e)
            {
                new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
            }
            return(false);
        }
 public static bool GetTableRowData(List <ImportLabDictErrorData> errorData)
 {
     BrowserUtilities.DS_SwitchToFrame();
     try
     {
         WebTable_SearchCriteriaItemList list = new WebTable_SearchCriteriaItemList();
         foreach (ImportLabDictErrorData data in errorData)
         {
             list.AddSearchItem(new WebTable_SearchCriteriaItem(0, data.WorkSheet, TableColumnContentType.Text));
             list.AddSearchItem(new WebTable_SearchCriteriaItem(1, data.Row, TableColumnContentType.Text));
             list.AddSearchItem(new WebTable_SearchCriteriaItem(2, data.Column, TableColumnContentType.Text));
             list.AddSearchItem(new WebTable_SearchCriteriaItem(3, data.Error, TableColumnContentType.Text));
             IControl processRow = WebTableUtilities.Table_FindRow(ImportLabDictionaryPage.ImportLabDictErrorTable, list);
             if (!Control_PropertyUtilities.IsControlNull(processRow))
             {
                 Control_ActionUtilities.Click(ImportLabDictionaryPage.ImportLabDictErrorTableOkButton, String.Empty);
                 BrowserUtilities.SwitchToWindow();
                 return(true);
             }
         }
         Control_ActionUtilities.Click(ImportLabDictionaryPage.ImportLabDictErrorTableOkButton, String.Empty);
         BrowserUtilities.SwitchToWindow();
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
        public static bool ClickYes(String titleText, String bodyMessageText_Partial)
        {
            BrowserUtilities.DS_SwitchToFrame();
            bool isClicked = false;

            if (IsModalExist_CheckHeaderTextAndBodyMessage(titleText, bodyMessageText_Partial))
            {
                isClicked = Control_ActionUtilities.ClickModalButton(CodeListsItemDeleteDialog.ClickYesButton);
            }
            BrowserUtilities.SwitchToWindow();
            return(isClicked);
        }
Exemplo n.º 4
0
 public static bool VerifyHeaderAndMessage(String titleText, String bodyMessageText_Partial)
 {
     if (BrowserUtilities.DS_SwitchToFrame())
     {
         if (IsModalExist_CheckHeaderAndMessage(titleText, bodyMessageText_Partial))
         {
             return(true);
         }
         BrowserUtilities.SwitchToWindow();
     }
     return(false);
 }
 public static bool StudyPublishContinueButton()
 {
     try
     {
         BrowserUtilities.DS_SwitchToFrame();
         bool isClicked = Control_ActionUtilities.Click(DS_LabMappingsSpecificationDialog.StudyPublishContinue, String.Empty);
         BrowserUtilities.SwitchToWindow();
         return(isClicked);
     }
     catch (Exception e)
     {
     }
     return(false);
 }
 public static bool ClickOnFilter()
 {
     BrowserUtilities.DS_SwitchToFrame();
     try
     {
         ImportLabDictionaryPage.FilterOption.WebElement.Click();
         BrowserUtilities.SwitchToWindow();
         return(true);
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
Exemplo n.º 7
0
 public static bool SaveButton()
 {
     BrowserUtilities.DS_SwitchToFrame();
     try
     {
         Control_ActionUtilities.Click(CodeListsGroupPage.SaveButton, String.Empty);
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
         return(false);
     }
     BrowserUtilities.SwitchToWindow();
     return(true);
 }
 public static bool ClickWarning(String warning)
 {
     BrowserUtilities.DS_SwitchToFrame();
     try
     {
         IControl warningLink = DS_StudyVerificationMessagesDialog.GetWarningLink(warning);
         Control_ActionUtilities.Click(warningLink, "Unable to click warning " + warning);
         BrowserUtilities.SwitchToWindow();
         return(true);
     }
     catch (Exception e)
     {
     }
     return(false);
 }
 public static bool ClickStudyLink(String linkName)
 {
     BrowserUtilities.DS_SwitchToFrame();
     try
     {
         Control_ActionUtilities.Click_PerssEnterKey(DS_HomePage.GetLink(linkName), "Unable to find link " + linkName + " in Designer Home Page");
         BrowserUtilities.SwitchToWindow();
         return(true);
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
Exemplo n.º 10
0
 public static bool ClickContinueButton()
 {
     try
     {
         BrowserUtilities.DS_SwitchToFrame();
         Control_ActionUtilities.ClickModalButton(ManageLabsPage.LabDictContinue);
         BrowserUtilities.SwitchToWindow();
         return(true);
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
Exemplo n.º 11
0
 public static bool StudyPublishLabel(String studyLabel)
 {
     try
     {
         BrowserUtilities.DS_SwitchToFrame();
         Control_ActionUtilities.Textbox_SetText(MapLabDictionary.StudyPublishLabel, studyLabel, String.Empty);
         BrowserUtilities.SwitchToWindow();
         return(true);
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
         return(false);
     }
 }
 public static bool ClickError(String error)
 {
     BrowserUtilities.DS_SwitchToFrame();
     try
     {
         IControl errorLink = DS_StudyVerificationMessagesDialog.GetErrorLink(error);
         Control_ActionUtilities.Click(errorLink, "Unable to click error " + error);
         BrowserUtilities.SwitchToWindow();
         return(true);
     }
     catch (Exception e)
     {
     }
     return(false);
 }
Exemplo n.º 13
0
        public static bool RemoveGroupCodelistItems(String countryName, String countryDesc)
        {
            String CodelistItem = countryName + " (" + countryDesc + ")";

            BrowserUtilities.DS_SwitchToFrame();
            if (AssociatedCodelistDropdownItem(CodelistItem))
            {
                if (Control_ActionUtilities.Click(CodeListsGroupPage.RemoveButton, String.Empty))
                {
                    Control_ActionUtilities.Click(CodeListsGroupPage.SaveButton, "Codelist Item successfully added to the group");
                    BrowserUtilities.SwitchToWindow();
                    return(true);
                }
            }
            return(false);
        }
 public static bool SearchInImportLabDictionaryErrors(string SelectDropDownOption, string dropDownList)
 {
     BrowserUtilities.DS_SwitchToFrame();
     try
     {
         ImportLabDictionaryPage.ErrorType.WebElement.Click();
         IControl dropDownOption = ImportLabDictionaryPage.SelectErrorFromDropDown(SelectDropDownOption, dropDownList);
         Control_ActionUtilities.CheckCheckbox(dropDownOption);
         BrowserUtilities.SwitchToWindow();
         return(true);
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
 public static bool VerifyErrorWarnings(List <StudyVerificationErrorsData> errorsList)
 {
     BrowserUtilities.DS_SwitchToFrame();
     try
     {
         foreach (StudyVerificationErrorsData error in errorsList)
         {
             IControl errorLink = DS_StudyVerificationMessagesDialog.GetErrorLink(error.Error);
             if (Control_PropertyUtilities.IsControlNull(errorLink))
             {
                 return(false);
             }
         }
         Control_ActionUtilities.Click(StudyVerificationMessagesPopup.Close, "Unable to click Close button");
         BrowserUtilities.SwitchToWindow();
         return(true);
     }
     catch (Exception e)
     {
     }
     return(false);
 }
Exemplo n.º 16
0
        public static bool SelectCodelist(String itemName)
        {
            BrowserUtilities.DS_SwitchToFrame();
            try
            {
                if (!String.IsNullOrEmpty(itemName))
                {
                    if (Control_ActionUtilities.Click(CodeListsGroupPage.CodelistGroupDropdownInvokerButton, "Unable to click the link"))
                    {
                        Control_ActionUtilities.Click(CodeListsGroupPage.GetCodelistGroupItem(itemName), "Unable to click the link");
                        BrowserUtilities.SwitchToWindow();
                        return(true);
                    }
                }
            }
            catch (Exception e)
            {
                new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
            }

            return(false);
        }
Exemplo n.º 17
0
        public static bool AddGroupCodelistItems(String countryName, String countryDesc)
        {
            String CodelistItem = countryName + " (" + countryDesc + ")";

            BrowserUtilities.DS_SwitchToFrame();
            if (!AssociatedCodelistDropdownItem(CodelistItem))
            {
                if (ClickAvailableCodelistDropdownItem(CodelistItem))
                {
                    if (Control_ActionUtilities.Click(CodeListsGroupPage.AddButton, String.Empty))
                    {
                        Control_ActionUtilities.Click(CodeListsGroupPage.SaveButton, "Codelist Item successfully added to the group");
                        BrowserUtilities.SwitchToWindow();
                        return(true);
                    }
                }
            }
            else
            {
                return(Control_ActionUtilities.Click(CodeListsGroupPage.CancelButton, "Codelist Item already associated to the group"));
            }
            return(false);
        }
 public static bool IsLabMappingsSpecificationDialogExist(String title, String message)
 {
     try
     {
         IControl titleControl = DS_LabMappingsSpecificationDialog.Title;
         if (!Control_PropertyUtilities.IsControlNull(titleControl) &&
             Control_PropertyUtilities.GetText(titleControl).Contains(title))
         {
             BrowserUtilities.DS_SwitchToFrame();
             IControl messageControl = DS_LabMappingsSpecificationDialog.Message;
             if (!Control_PropertyUtilities.IsControlNull(messageControl) &&
                 Control_PropertyUtilities.GetText(messageControl).Contains(message))
             {
                 BrowserUtilities.SwitchToWindow();
                 return(true);
             }
         }
     }
     catch (Exception e)
     {
     }
     return(false);
 }
 public static bool WhenISelectThePopupWindow(string title, string message)
 {
     return(BrowserUtilities.DS_SwitchToFrame());
 }