# Identify dynamic name using Scrubyt

**URL:** <https://www.ruby-forum.com/t/identify-dynamic-name-using-scrubyt/167754>\
**Category:** Rails\
**Created:** [May 12, 2009, 9:29am UTC](https://www.ruby-forum.com/t/identify-dynamic-name-using-scrubyt/167754 "2009-05-12T09:29:56Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![saurabhpurnaye](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/ee59a6/32.png) [@saurabhpurnaye](https://www.ruby-forum.com/u/saurabhpurnaye)\
**Post date:** [May 12, 2009, 9:29am UTC](https://www.ruby-forum.com/t/identify-dynamic-name-using-scrubyt/167754/1 "2009-05-12T09:29:56Z")

</div>

Hi All,

I’m trying to execute the following code.

url = “[https://xxx.com](https://xxx.com)”(some url)  
ebay\_data = Scrubyt::Extractor.define :agent =\> :firefox do  
fetch(url)  
fill\_textfield field name, value  
record “//table[@id=‘header’]” do  
name “//input[@class=‘req’]”  
end  
end

Code executes properly for static name of textfield

But the url which i’m trying to fetch is having dynamic name so when i  
try to run the code it gives me error:

Unable to locate element, using :name, “”  
(Watir::Exception::UnknownObjectException)

Every time the name changes on refresh. Please suggest me how should I  
fill the text field of a url with dynamic text\_field name. (Using  
Scrubyt)

Thanks  
Saurabh
