babs_de Posted July 25, 2012 Share Posted July 25, 2012 Hello! I can not understand how the Flash function substr(), substring() in Unigine. / / / / / / / / / / / / / Example / / / / / / / / / / / / / / / / / var str: String = '1234567890 '; trace (str.substr (1, 4)); / / Works to swf 2345 / / In Unigine does not work: FlashVariable :: getObjectSafe (): can't run "substr" function, object is NULL FlashInterpreter :: runActions (): can't convert string to object indefined Thank you. Link to comment
frustum Posted July 25, 2012 Share Posted July 25, 2012 Please use the following syntax: var str: String = new String('1234567890 '); trace (str.substr (1, 4)); Link to comment
Recommended Posts