Sign in to follow this  
Followers 0
shaggy89

splitting it up

2 posts in this topic

Hi all,

        I need some help working out how to split some code.

The website shows how many staff are avalible for day shift and night shft seperated by a /

so what im trying to work out is how to only show the first number

This is what i have so far

for example i have 3 for day and 4 for night

$oSpan = _IETagNameGetCollection($oIE, "span", 3)
$msg = $oSpan.innerText
$ms = StringTrimRight ( $msg, 2)
;local $msg = _StringBetween($sText, ";", "/")
MsgBox(64, "Results", $ms)

reslut comes up as 3/ in msg box

so how can i remove the /

in the end im hoping to get an auto email if day number is lower than 5

any ideas?

cheers Shane

Share this post


Link to post
Share on other sites



problem solved

$oSpan = _IETagNameGetCollection($oIE, "span", 3)
$msg = $oSpan.innerText
$ms = StringTrimRight ( $msg, 3)
;local $msg = _StringBetween($sText, ";", "/")
MsgBox(64, "Results", $ms)

had to change $ms = StringTrimRight ( $msg, 2) to $ms = StringTrimRight ( $msg, 3)

simple just needed a cup of coffee

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  
Followers 0