Login
`
Templates, Tools and Utilities
|
||
Icetips Article
Back to article list
Search Articles
Add Comment
Printer friendly
Direct link
Clarion in general: Extracting an image list out of web page 2003-07-30 -- Jeff Slarve Newsgroups: comp.lang.clarion
Might as well let the big boys do your work for you<g>
Program
map
end
Window WINDOW('Image Counter'),AT(,,419,233),|
FONT('MS Sans Serif',8,,FONT:regular,CHARSET:ANSI),CENTER, |
IMM,GRAY,MAX,RESIZE
OLE,AT(3,3,414,207),USE(?Ole1)
END
BUTTON('Get Images'),AT(3,215,45,14),USE(?Button1)
END
Q Queue
Image String(255)
end
ListWindow WINDOW('Images'),AT(,,417,203),|
FONT('MS Sans Serif',8,,FONT:regular,CHARSET:ANSI),CENTER,SYSTEM, |
GRAY,DOUBLE
LIST,AT(3,2,409,198),USE(?List1),VSCROLL,FORMAT('200L(2)|M~Image~'),FROM(Q)
END
ndx long
Code
Open(Window)
?Ole1{PROP:Create}='Shell.Explorer.2'
?Ole1{'navigate("http://www.cnn.com")'}
Ndx = 0
Accept
Case Accepted()
of ?Button1
Loop Ndx = 0 to ?Ole1{'document.images.length'} - 1
Q.Image = ?Ole1{'document.images(' & ndx & ').src'}
If NOT Q.Image then break.
Add(Q)
end
break
end
end
Close(Window)
Open(ListWIndow)
0{PROP:Text} = Records(Q) & ' Images'
Accept
end
On Wed, 30 Jul 2003 14:55:33 -0500, "Tim Morrison"
Today is November 21, 2024, 3:51 am This article has been viewed 35227 times. Google search has resulted in 150 hits on this article since January 25, 2004.
|
|