Code: Select all
numpad1::
H =
(
....
<span class="pv-test-category-entity__name-text t-16 t-black t-bold"> Wellness </span> ... </a><!---->
</p> <span class="pv-test-category-entity__name-text t-16 t-black t-bold"> Nutrition Education</span></a><!----> </p>
... <span class="pv-test-category-entity__name-text t-16 t-black t-bold"> Research </span>
</a>
<!----> </p> ... <span class="pv-test-category-entity__name-text t-16 t-black t-bold"> Sports Nutrition </span>
</a>
<!----> </p> ...
...
)
B := "name-text t-16 t-black t-bold"">" ; Begin match
E := "</span>" ; End match
P1 := InStr(H, B) ; Position of Begin match
P2 := InStr(H, E) ; Position of End match
Res := SubStr(H, P1:=P1+StrLen(B), P2-P1)
sleep, 200
msgbox %Res% ; shows Wellness only. but I want Nutrition Education, Research, Sports Nutrition etc.
;fileappend, %Res%, test.txt
return