can you post the error you get? ALso, what happens when yo click the link? If you go somewhere else, are you still in the loop, trying to access things that re not there any more? ie change .click to .flash and see if it works - then the problem is you are trying to access things that no longer exist
Paul ----- Original Message ----- From: "Dave Munns" <[EMAIL PROTECTED]> To: <[email protected]> Sent: Friday, October 13, 2006 4:04 PM Subject: [Wtr-general] Memory access errors >I have built a test tool that has suddenly started terminating with memory >access errors. > The culprit appears to be code that I have added to traverse links in a > frame, and if a link exists, it clicks on that link. Using the eclipse IDE > debugger, the code appears to be working as expected. I am using Ruby > 1.8.5.21 and Watir 1.5.1.1100 with IE 6.x on W2k3 V5.2 w/ SP1. > > Any tips for debugging the memory access error? It happens in different > locations in the test tool, but never gets to execute code that actually > clicks the links. Code snippet (dots added for readability): > > def Clickaway > ..if $clickonlistelements == "true" > .....theIndex = 0 > .....while theIndex < $maxiterations > ........theIndex = theIndex + 1 > ........if( > $ie.frame("fraDataZone").frame("fraDataZoneList").frame(:index,1).span(:index, > > theIndex).exists? ) > ..........puts "ECMTC_ClickonAllElements: INFO: list element exists, > clicking..." > ..........$ie.frame("fraDataZone").frame("fraDataZoneList").frame(:index,1).span(:index, > > theIndex).click > ........else > ..........puts "ECMTC_ClickonAllElements: INFO: no list elements exist" > ..........theIndex = $maxiterations # done with loop > ........end > ......end > end > end > --------------------------------------------------------------------- > Posted via Jive Forums > http://forums.openqa.org/thread.jspa?threadID=4779&messageID=13206#13206 > _______________________________________________ > Wtr-general mailing list > [email protected] > http://rubyforge.org/mailman/listinfo/wtr-general > _______________________________________________ Wtr-general mailing list [email protected] http://rubyforge.org/mailman/listinfo/wtr-general
