Hi All,

Please help me in writing a code to get the font style of WebElement

For Example:
URL: http://newtours.demoaut.com/
Webelement :$398

Here in this Page the Web element is BOLD in Font and Font Size is 10
but i dont find this when i debug this below code...

Dim ctrlWebEl, objWebEl


Set ctrlWebEl = Browser("Send Email").Page("Welcome: Mercury
Tours").WebElement("$398")
Set objWebEl = ctrlWebEl.Object

sColor = objWebEl.currentStyle.fontStyle
msgbox sColor  -- Gives Normal
sBackgrColor = objWebEl.currentStyle.backgroundColor
msgbox sBackgrColor
sFontSize = objWebEl.currentStyle.fontSize
msgbox sFontSize
sFontStyle = objWebEl.currentStyle.fontStyle
msgbox sFontStyle
sFontFamily = objWebEl.currentStyle.fontFamily
msgbox sFontFamily
sFontWeight = objWebEl.currentStyle.fontWeight
msgbox sFontWeig

I searched in the Discussion group and also googled but dint find any
solution..
Kindly Help me...

Regards,
Krishna

-- 
You received this message because you are subscribed to the Google
"QTP - HP Quick Test Professional - Automated Software Testing"
group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/MercuryQTP?hl=en

Reply via email to