Hi Srinadh,
Could you please try the below code? Not sure whether the small scroll bar is in a different frame. Please check that.
'For page up
Set bodyObj=Browser("title:=.*").Page("title:=.*").Object.body
bodyObj.doScroll("pageUp")
'For page down
Set bodyObj=Browser("title:=.*").Page("title:=.*").Object.body
bodyObj.doScroll("pageDown")
(Or) Using Send Keys method:
'For page up
Set shellObj=CreateObject("WScript.Shell")
shellObj.SendKeys "{PGUP}"
'For page down
Set shellObj=CreateObject("WScript.Shell")
shellObj.SendKeys "{PGDN}"
Regards,
Madhu
Regards,
Madhu
Try this ..Here We are automating Mousewheel using loop..
Extern.Declare micVoid, "mouse_event", "user32.dll", "mouse_event", micLong, micLong, micLong, micLong, micLong
Const MOUSEEVENTF_WHEEL = 2048 '@const long | MOUSEEVENTF_WHEEL | middle button up
Const POSWHEEL_DELTA = 120 '@const long | POSWHEEL_DELTA | movement of 1 mousewheel click Down<nl>
Const NEGWHEEL_DELTA = -120 '@const long | NEGWHEEL_DELTA | movement of 1 mousewheel click Up<nl>
Sub MouseWheelRot(iClicks)
dim iLoop
dim bPos
if iClicks > 0 then
bPos = true
end if
for iLoop = 1 to abs(iClicks)
if bPos then
Extern.mouse_event MOUSEEVENTF_WHEEL,0,0,POSWHEEL_DELTA,0
else
Extern.mouse_event MOUSEEVENTF_WHEEL,0,0,NEGWHEEL_DELTA,0
end if
next
End SubSet obj=CreateObject("Mercury.DeviceReplay")
set wS = CreateObject("WScript.Shell")
Set vE = Browser(vB).page(vP).WebElement(vS)
vX = vE.GetROProperty("abs_x")
vY = vE.GetROProperty("abs_y")
'Scrolling mouse
obj.MouseClick vX+650, vY+25, 2
wS.SendKeys "{DOWN}"
wS.SendKeys "{DOWN}"
wS.SendKeys "{DOWN}"
wS.SendKeys "{ENTER}"