07-25-2013, 10:40 AM
I probably will be able to modify the code to suit better but wouldnt guarantee that it will validate the functionality you are looking for. I would request you to elaborate more on what you intend to do?
Please be aware that if you are not keen on Character casing then you may want to use Ucase or Lcase to format both the strings to a particular case and then perform a Comparision. Because, Strcomp function will fail if the character cases are different.
Code:
If str_TestCaseId="TC007_PolicySearch_By_FirstAndLastName" Then
GetReturnedName=Browser(".").Page(".").WebElement(".").GetROProperty("innerhtml")
ReturnedNameFormat= str_LastName&","&" "&str_FirstName
If StrComp(Trim(GetReturnedName),Trim(ReturnedNameFormat))>0 Then
Reporter.ReportEvent micPass, "Search returned proper format of insured name by searching First and last name",""
Else
Reporter.ReportEvent micFail,"Search did not return proper format of insured name by searching First and last name", ""
End If
End If
Basanth
Give a fish to a man and you feed him for a day..Teach a man how to fish and you feed him for life.
Give a fish to a man and you feed him for a day..Teach a man how to fish and you feed him for life.