Unable to manipluate popup

119 views
Skip to first unread message

Brian Susol

unread,
Mar 17, 2024, 8:29:33 AM3/17/24
to Selenium Users

I have a web application I have been working with and creating automations. I have hit a block on on a specific step where I click a button, which then opens a popup. On this popup there is only a dropdown and a button to submit.  I am unable to manipulate this button and dropdown

popup.png

I think this might be a modal container. I have attached a copy of the code for the page as it was too much to just paste in here.

I have looked into tutorials for modals and tried a number of things, but so far, I am still having some challenges here. I pasted the code below and also attached a file for easier reading

I'm a little stumped as to how to proceed. Does anyone have any thoughts?

   //NEW PAGE - FINISH RAW MATERIAL SETUP

            //Raw Material Mill Selection

            //WebElement rMatMill=driver.findElement(By.id("bom-common-rawmaterialscreencreate-raw-material-mill-button")); 

            WebElement rMatMill=driver.findElement(By.xpath("/html//button[@id='bom-common-rawmaterialscreencreate-raw-material-mill-button']"));

            Thread.sleep(1000);

            rMatMill.click();

           

           

           

            //(By.xpath("/html//select[contains(@id,'bom-common-rawmaterialscreen-calculationtype')]"));

           

            WebElement modalContainer = driver.findElement(By.className("modalBlockout"));

           

            //WebElement modalContentBody = driver.findElement(By.xpath("/html//div[@class='modalHost ui-front']/div"));

           

            WebElement modalContentBody = driver.findElement(By.className("ui-dialog ui-widget ui-widget-content ui-corner-all ui-dialog-buttons tixui5-modal-dialog ui-draggable ui-resizable"));

           

            WebElement modalRawMatMill = modalContentBody.findElement(By.xpath("/html//select[contains(@id,'bom-common-dialogs-copyrawmaterialmilldialogmillcode-combo')]"));

            Select modalRawMatMillDD = new Select(modalRawMatMill);

            modalRawMatMillDD.selectByIndex(0);

           

            //modalRawMatMillDD.click();




modal attempts.txt
code for popup.txt

Anjali Tandel

unread,
Mar 17, 2024, 11:54:53 PM3/17/24
to seleniu...@googlegroups.com
Hey Brain Susol,

It will be possible to give that page like so i can check it out, and let you know.

Thanks
Anjali


--
You received this message because you are subscribed to the Google Groups "Selenium Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to selenium-user...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/selenium-users/8cbc402c-fe6e-4ec8-ad54-b1e224430f75n%40googlegroups.com.

Brian J. Susol

unread,
Mar 18, 2024, 5:51:40 AM3/18/24
to seleniu...@googlegroups.com
i wish i could.  but it’s a web based ERP and not public facing.

i’ve actually gotten pretty far in the process. A few times i wondered if it wasn’t a typical site but i’ve figured out ways to get what i needed.   At least till now….  Trying to crack the last bit of this code now. 

Brian 


You received this message because you are subscribed to a topic in the Google Groups "Selenium Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/selenium-users/zCXosR95uJ0/unsubscribe.
To unsubscribe from this group and all its topics, send an email to selenium-user...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/selenium-users/CAP8NYyGKTcYehHWf1BWSO0RbfzLkaDwhLTe9bmJKLc9P-yv2NA%40mail.gmail.com.

Anjali Tandel

unread,
Mar 18, 2024, 7:28:49 AM3/18/24
to seleniu...@googlegroups.com
Reply all
Reply to author
Forward
Message has been deleted
0 new messages