Jump to content
Sign in to follow this  

How to find flash object in the IExplorer and click it ?

Recommended Posts

---------------- HTML SRC ----------------


<OBJECT id=start02






<PARAM NAME="_cx" VALUE="5318">

<PARAM NAME="_cy" VALUE="2143">

<PARAM NAME="FlashVars" VALUE="">

<PARAM NAME="Movie" VALUE="/d_fighter/swf/start_ver2.swf?nocache=1198131784"><PARAM NAME="Src" VALUE="/d_fighter/swf/start_ver2.swf?nocache=1198131784">

<PARAM NAME="WMode" VALUE="Transparent"><PARAM NAME="Play" VALUE="0"><PARAM NAME="Loop" VALUE="-1"><PARAM NAME="Quality" VALUE="High"><

PARAM NAME="SAlign" VALUE=""><PARAM NAME="Menu" VALUE="-1"><PARAM NAME="Base" VALUE=""><PARAM NAME="AllowScriptAccess" VALUE="sameDomain">

<PARAM NAME="Scale" VALUE="ShowAll"><PARAM NAME="DeviceFont" VALUE="0"><PARAM NAME="EmbedMovie" VALUE="0"><PARAM NAME="BGColor" VALUE="">

<PARAM NAME="SWRemote" VALUE=""><PARAM NAME="MovieData" VALUE=""><PARAM NAME="SeamlessTabbing" VALUE="1"><PARAM NAME="Profile" VALUE="0">

<PARAM NAME="ProfileAddress" VALUE=""><PARAM NAME="ProfilePort" VALUE="0"><PARAM NAME="AllowNetworking" VALUE="all"><PARAM NAME="AllowFullScreen" VALUE="false">

<embed src='/d_fighter/swf/start_ver2.swf?nocache=1198131784' wmode='transparent' quality='high' width='201' height='81' align='middle' allowScriptAccess='sameDomain'

type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer' /></OBJECT>



my code was below...

$oApplets = $oIE.document.applets

$iNumApplets = $oIE.document.applets.length

for $i = 0 to ($iNumApplets - 1)

$oApplet = $oIE.document.applets($i)

{ Need some code to find target flash active-x }


I could not find Flash active-x object.... anybody have a idea ??


Share this post

Link to post
Share on other sites

From the looks of it, the easiest way would be

$oApplet = _IEGetObjById($oIE, "start02")

If you need to pick it up in the loop, you can examine its properties like .codebase or .classid and look for string matches.


Edit: oh, and to click it, if you don't care where you click it you can just use _IEAction($oApplet, "click")

If you need to do it by coordinates, look at _IEPropertyGet to retrieve screen or browser-based geometry for the object and then use MouseClick

Edited by DaleHohm

Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl

MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model

Automate input type=file (Related)

Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded  Better Better?

IE.au3 issues with Vista - Workarounds

SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead?

Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble

Share this post

Link to post
Share on other sites


I'm wondering how i can click on a flash object embedded in a webpage from classid if there is no object_id?:-


<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="https://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="518" height="140">

<param name="movie" value="html/flash/games/bingolobby.swf">

<param name="FlashVars" value="logo=/html/flash/games/bingo/vip/logo.swf&room=2&type=3&session_id=&info_url=2.txt&access_control=0">

<param name="quality" value="high">

<param name="wmode" value="transparent" >

<embed src="html/flash/games/bingolobby.swf" FlashVars="logo=/html/flash/games/bingo/vip/logo.swf&room=2&type=3&session_id=&info_url=2.txt&access_control=0" quality="high" pluginspage="https://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" wmode="transparent" width="518" height="140"></embed>



$oApplet = _IEGetObjById($oIE, <classid>)

_IEAction($oApplet, "click")

Many Thanks for any help anyone can be at this time.



Share this post

Link to post
Share on other sites

Global $oApplet, $oObjectCollection = $oIE.document.getElementsByTagName('object')

For $oApplet In $oObjectCollection

   If StringInStr(String($oApplet.classid),"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000") Then _



; $oApplet holds ur object now

Edited by 4ggr35510n

Share this post

Link to post
Share on other sites
This topic is now closed to further replies.
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Create New...