Jump to content
Sign in to follow this  
redfenix

Help for list images found on a website

Recommended Posts

redfenix

[sorry for my english]

I need help for my script, after i download html source from website, i must list images with specific extension in an array. So take all array data and insert these in a ListView (Form).

I would like to know how to do this.

I hope I explained correctly, Thanks in advance

Share this post


Link to post
Share on other sites
water

Have a look at the IE UDF which comes with AutoIt.

Function _IEImgGetCollection should return "a collection object variable representing the IMG tags in the document or a single image by index."


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2018-06-01 - Version 1.4.9.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (2018-01-27 - Version 1.3.3.1) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2015-04-01 - Version 0.4.0.0) - Download - General Help & Support - Example Scripts
Excel - Example Scripts - Wiki
Word - Wiki
PowerPoint (2015-06-06 - Version 0.0.5.0) - Download - General Help & Support

Tutorials:
ADO - Wiki

 

Share this post


Link to post
Share on other sites
redfenix

Thanks, if i want get video files??

Share this post


Link to post
Share on other sites
water

You were talking about images. What do you need: images or videos?


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2018-06-01 - Version 1.4.9.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (2018-01-27 - Version 1.3.3.1) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2015-04-01 - Version 0.4.0.0) - Download - General Help & Support - Example Scripts
Excel - Example Scripts - Wiki
Word - Wiki
PowerPoint (2015-06-06 - Version 0.0.5.0) - Download - General Help & Support

Tutorials:
ADO - Wiki

 

Share this post


Link to post
Share on other sites
redfenix

Both really :)

Share this post


Link to post
Share on other sites
water

Then I would first do the image thing as I suggested above. When you succeed you can do the video stuff.


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2018-06-01 - Version 1.4.9.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (2018-01-27 - Version 1.3.3.1) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2015-04-01 - Version 0.4.0.0) - Download - General Help & Support - Example Scripts
Excel - Example Scripts - Wiki
Word - Wiki
PowerPoint (2015-06-06 - Version 0.0.5.0) - Download - General Help & Support

Tutorials:
ADO - Wiki

 

Share this post


Link to post
Share on other sites
redfenix

#include 
#include 
#include 
#include 
#Include 

Opt("GUIOnEventMode", 1)
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("ImgTest", 497, 208, 501, 344)
GUISetOnEvent($GUI_EVENT_CLOSE, "Form1Close")
$List = GUICtrlCreateListView("", 16, 32, 465, 161)
_GUICtrlListView_InsertColumn($List, 0, "Filename", 120)
_GUICtrlListView_InsertColumn($List, 1, "Source", 200)
_GUICtrlListView_InsertColumn($List, 2, "WxH", 140)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

Search()

While 1
Sleep(100)
WEnd

Func Form1Close()
Exit
EndFunc

Func Search()
Local $ie = _IECreate("http://www.autoitscript.com/",0,0)
Local $imgs = _IEImgGetCollection($ie)
Local $nImg = @extended
$num = -1
For $img In $imgs
$num = $num + 1
_GUICtrlListView_AddItem($List, $img.nameprop, $num)
_GUICtrlListView_AddSubItem($List, $num, $img.src,1)
_GUICtrlListView_AddSubItem($List, $num, $img.width & "x" & $img.height,2)
Next
EndFunc

Ok and now, for video files?

Edited by redfenix

Share this post


Link to post
Share on other sites
water

Use function _IETagNameGetCollection to get a collection of all "video" tags or however they are tagged.


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2018-06-01 - Version 1.4.9.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (2018-01-27 - Version 1.3.3.1) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2015-04-01 - Version 0.4.0.0) - Download - General Help & Support - Example Scripts
Excel - Example Scripts - Wiki
Word - Wiki
PowerPoint (2015-06-06 - Version 0.0.5.0) - Download - General Help & Support

Tutorials:
ADO - Wiki

 

Share this post


Link to post
Share on other sites
redfenix

I can't understand how to use this function, can you give me an example? Or another function...

Share this post


Link to post
Share on other sites
water

Did you have a look at the example script in the help file?


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2018-06-01 - Version 1.4.9.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (2018-01-27 - Version 1.3.3.1) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2015-04-01 - Version 0.4.0.0) - Download - General Help & Support - Example Scripts
Excel - Example Scripts - Wiki
Word - Wiki
PowerPoint (2015-06-06 - Version 0.0.5.0) - Download - General Help & Support

Tutorials:
ADO - Wiki

 

Share this post


Link to post
Share on other sites
redfenix

Thanks for all, done!

Share this post


Link to post
Share on other sites
careca

Weird, but, sometimes my posts "remove" the includes, just as your's, was it on purpose?


Spoiler

Paster - Main function is to paste text, but has more functions. (No longer mantained, switched to String Trigger)

Renamer - Rename files and folders, remove portions of text from the filename etc.

GPO Tool - Export/Import Group policy settings.

BeatsPlayer - Music player.

Params Tool - Right click an exe to see it's parameters or execute them.

String Trigger - Triggers pasting text or applications or internet links on specific strings.

Inconspicuous - Hide files in plain sight, not fully encrypted.

Regedit Control - Registry browsing history, quickly jump into any saved key.

Time4Shutdown - Write the time for shutdown in minutes.

Power Profiles Tool - Set a profile as active, delete, duplicate, export and import.

Firefox Profile Backup - Backup/restore previously saved profile.

Finished Task Shutdown - Shuts down pc when specified window/Wndl/process closes.

NetworkSpeedShutdown - Shuts down pc if download speed goes under "X" Kb/s.

IUIAutomation - Topic with framework and examples

Au3Record.exe

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×