11-02-2011, 10:57 AM
Hi Azad,
Ur Code..
The above code will not work as the outerhtml property contains few special characters($,.). You need to ignore\escape these characters using Regular expression escape character...
Use the below code and see if it works..
OR
=================================================================
There is one more solution to your issue if you know what value you are looking for on the page.
now strPageContent will contain all the data present on the page. You can use the Instr function to search for your value.
Do let me know if this desn't help or if you have any other query.
Regards,
Ankesh
Ur Code..
Code:
Datatable.GlobalSheet.AddParameter"MPI",""
DataTable("MPI","Global")= Browser("micclass:=Browser").Page("micclass:=Page").WebElement("html tag:=H3","outerhtml:=<H3>$2,997.75</H3>").GetRoProperty("innertext")
The above code will not work as the outerhtml property contains few special characters($,.). You need to ignore\escape these characters using Regular expression escape character...
Use the below code and see if it works..
Code:
DataTable("MPI","Global")= Browser("micclass:=Browser").Page("micclass:=Page").WebElement("html tag:=H3","outerhtml:=<H3>\$2,997\.75</H3>").GetRoProperty("innertext")
Code:
DataTable("MPI","Global")= Browser("micclass:=Browser").Page("micclass:=Page").WebElement("html tag:=H3","outerhtml:=\<H3\>\$2,997\.75\<\/H3\>").GetRoProperty("innertext")
=================================================================
There is one more solution to your issue if you know what value you are looking for on the page.
Code:
strPageContent=Browser(<BrowserName>).Page(<PageName>).Object.body.innertext
now strPageContent will contain all the data present on the page. You can use the Instr function to search for your value.
Do let me know if this desn't help or if you have any other query.
Regards,
Ankesh