I have this code for copy paste values… in mode headless chrome , the values are not paste in the page
public void pasteValuesFromClipboard(WebDriver webDriver, Strategy strategy){
try{
WebElement web_ApMax
WebElement web_ApMin
WebElement web_seatIndex
WebElement web_valorBP
WebElement web_textArea
TestObject textAreaInTable = ObjectRepository.findTestObject(“Object Repository/Pages/Mantenedor/DetallesEstrategias/TableStrategyInputDataField”)
String xpathBaseTableStrategy = ObjectRepository.findTestObject(“Object Repository/Pages/Mantenedor/DetallesEstrategias/tableStrategyTbody”).findPropertyValue(“xpath”)
int index=1
for(StrategyDetails detail : strategy.strategyDetails){
web_ApMax = webDriver.findElement(By.xpath(xpathBaseTableStrategy + “/tr[”+ index +“]/td[1]”))
web_ApMin = webDriver.findElement(By.xpath(xpathBaseTableStrategy + “/tr[”+ index +“]/td[2]”))
web_seatIndex = webDriver.findElement(By.xpath(xpathBaseTableStrategy + “/tr[”+ index +“]/td[3]”))
web_valorBP = webDriver.findElement(By.xpath(xpathBaseTableStrategy + “/tr[”+ index +“]/td[4]”))
clicOnElement(web_ApMax, 1)
web_textArea = webDriver.findElement(By.xpath(textAreaInTable.findPropertyValue(“xpath”)))
addToClipboard(detail.APMax + “\t”)
web_textArea.sendKeys(Keys.CONTROL+ “v”)
addToClipboard(detail.APMin + “\t”)
web_textArea.sendKeys(Keys.CONTROL+ “v”)
addToClipboard(detail.SeatIndex + “\t”)
web_textArea.sendKeys(Keys.CONTROL+ “v”)
addToClipboard(detail.ValorBP)
web_textArea.sendKeys(Keys.CONTROL+ “v”)
web_textArea.sendKeys(Keys.ENTER)
index++
}
}catch(Exception e){
KeywordUtil.markFailed("Ocurrió un error al insertar detalles de la estrategia: " + e.message)
}
}
someone, can helpme please?