scaper12123
9 years agoVisitor
can xml reference functions outside of xml?
I have a function I use to record time that I want to reference in an xml document I'm using to create a countdown timer. Is the code within the xml document capable of recognizing that I am referencing a function within my primary brightscript documents, or do I have to do something special to point that fact out?
to clarify, I have this in the xml document
And I have this in a brs document
to clarify, I have this in the xml document
sub changeTime(seconds as integer)
m.label.text = CountdownTime(seconds)
return
end sub
And I have this in a brs document
function CountdownTime(seconds as integer) as string
h = seconds / 3600
m = (seconds - h * 3600) / 60
s = seconds Mod 60
Return h.ToStr() + ":" + Right("0" + m.ToStr(), 2) + ":" + Right("0" + s.ToStr(), 2)
end function