Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Read YouTube links/numbers
#2
Macro Macro2816
Code:
Copy      Help
int w=act(win("" "Chrome_WidgetWin_1"))
lef 141 9 w 1 ;;Text ''
Acc a.Find(w "DOCUMENT" "" "" 0x3010 2)
ARRAY(Acc) aa; int i
ARRAY(str) aURL
a.GetChildObjects(aa -1 "LINK" "Facebook|Twitter|Twitch|Instagram" "" 2)
for i 0 aa.len
,Acc& r=aa[i]
,str name=r.Name
,str url=r.Value
,out "%-35s %s" aa[i].Name aa[i].Value
,aURL[]=url

int w1=act(win("test - Editor" "Notepad"))
paste aURL

for i 0 aURL.len
,run aURL[i]

Quote:Another thing I would like to do is to get the subscriber / total views number.
Problematic here is that its not always the same amount of numbers (e.g. 10.000 vs 1.000.000 subscribers).
How can I get started here?
Macro Macro2818
Code:
Copy      Help
int w=wait(3 WV win(" - YouTube - Google Chrome" "Chrome_WidgetWin_1"))
Acc a.FindFF(w "span" "" "class=yt-subscription-button*" 0x1004 3|4)
str s=a.Description
s.findreplace("."); s.findreplace(",") ;;remove thousand separators
int n=val(s)
out n


Messages In This Thread

Forum Jump:


Users browsing this thread: 4 Guest(s)