The above will create a web driver wait object that will wait for up to 15 second (checking the condition every 100ms) for the element to become invisible. This will pass straight away if the element is already invisible when the line of code is triggered.

Edit based upon comments below

If you are just trying to find out if an element exists of not you can do:

I tried but it is not working ,as I mentioned before that it appears only when error message appears. Otherwise webdriver does not respond.
–
user1948674Feb 22 '13 at 17:07

I guess I'm not clear what you are asking for, I was under the impression you wanted to verify that an element had become invisible. What are you really trying to do?
–
ArdescoFeb 24 '13 at 20:19

I want to capture error message on Textbox's Tab out action if it appears ,not then it should enter second field's data.I am able to capture error messages if both labels are displaying error.If one doesn't show error message then it dont enter second field data,continuously search xpath for first error label.HTML is: label class="error" generated="true" for="userName" label .If I am not wrong ,to seeing HTMLs ,it enables only at the wrong data entry
–
user1948674Feb 25 '13 at 12:28

if error message is not displaying then HTML also is not displaying for error label
–
user1948674Feb 25 '13 at 12:56