Try using some other element property like name or value instead of id. You could find their values using developer's tool bar.
2010/11/18 Hrishikesh Bose <hrishikesh.b...@gmail.com> > may be i am new to the Watir. > > The problem i am facing is as following. > > > . i need to automate a use case which is like a new window. i provide name > and password and click save to create a new user. > > Now the Name and Password are text fields. I can get the ids using > developer tool bar. but the next time i reload the page and try to run the > automation script again, the text_field ids get changed to a new value and > my test script fails > > so the first time i select the text field i get <INPUT id="c_179" > > > Once the page is reloaded i get <INPUT id="c_2"> > > > what i should do so that even if these IDs are changing i can find the same > element. > > thanks, > hrishikesh bose > > > On Thu, Nov 18, 2010 at 3:14 PM, Željko Filipin < > zeljko.fili...@wa-research.ch> wrote: > >> On Thu, Nov 18, 2010 at 10:32 AM, Hrishikesh Bose < >> hrishikesh.b...@gmail.com> wrote: >> > so got this questions on whether we can use WATIR to automate AJAX web >> pages. >> >> You should be able to do it. Most of us automate web applications with a >> lot of javascript. Let us know if you have a problem with someting. >> >> Željko >> -- >> watir.com - community manager >> watirpodcast.com - host >> testingpodcast.com - audio podcasts on software testing. all of them >> >> -- >> Before posting, please read http://watir.com/support. In short: search >> before you ask, be nice. >> >> watir-general@googlegroups.com >> http://groups.google.com/group/watir-general >> watir-general+unsubscr...@googlegroups.com<watir-general%2bunsubscr...@googlegroups.com> >> > > -- > Before posting, please read http://watir.com/support. In short: search > before you ask, be nice. > > watir-general@googlegroups.com > http://groups.google.com/group/watir-general > watir-general+unsubscr...@googlegroups.com<watir-general%2bunsubscr...@googlegroups.com> > -- Before posting, please read http://watir.com/support. In short: search before you ask, be nice. watir-general@googlegroups.com http://groups.google.com/group/watir-general watir-general+unsubscr...@googlegroups.com