Can anyone help me retrieve the value from the span tag in this scenario? The class name is consistent, but if there is an error in any of the fields belonging to that class, the text will become visible. For instance, consider the following two fields: 1) depositorname 2) company name If the company name is incorrect, a message saying "Company name not found" will be displayed within a span tag while the depositorname span tag remains without a linktext value. sameclass