A beginner's question on exceptional handling,please help

Hi All,

In my code i am getting this exception.

(Watir::Exception::UnknownObjectException)

Can anybody help how to handle it

When this exception raises i want to do 1 operation

1. $IE0.image(:src, "
http://172.16.5.89/~tanu/nebo/src/www/images/wizards1.png").click

when there is no exception i want to do 2 operation

2. $IE0.image(:src, "
http://172.16.5.89/~tanu/nebo/src/www/images/wizards.png").click

3.some operations i want to do always no matter exception is there or not.

Please help me soon,i need to fix it soon.

Thanks in Advance.

begin
   # .. process
rescue
   # .. handle error
ensure
   # .. some code
end

See also: http://www.rubycentral.com/book/tut_exceptions.html

cu
pp