loadVars from csv into dropdown search box

I need a little help entering csv variables into multiple search bars that are each within their own dropdowns. I’ve used Record to create a test case where I entered values via keyboard then hit Enter to select the searched value and would like to replace the search terms with csv variables.

My current attempt reads:
type | xpath=(//input[@type=‘text’])[2] | ${amount}
sendKeys | xpath=(//input[@type=‘text’])[2] | ${KEY_ENTER}

If I delete all commands after the type | input | ${amount} line, it shows the value from the csv in the search box. However, it seems KEY_ENTER is not registering on playback before the next click Command is given, which negates the search and returns it to default.

Assistance on how to get this search entered would be greatly appreciated!

It works fine in Firefox.

did you try to set different speed of replaying script?
seems like you need to delay next command after key input.

I tried a couple wait commands giving them up to a second, but wasn’t sure that I was implementing them correctly. One seemed like it was working but not fixing the issue.
I’m not a tester, I was just trying to use this to automate repetitive submissions on a site. So when firefox simply worked, that became my fix.

1 Like


Hi, we rolled out a fix for SendKeys, please check to see if it works on Chrome. Try record the submit action again as well.