AS3 - Regular Expression 移除字串空白

var rex:RegExp = /[\s\r\n]*/gim; 
var str:String = "This is a string."; 
str = str.replace(rex,'');


Regular Expression 詳細介紹
 http://blog.roodo.com/rocksaying/archives/2670695.html

沒有留言:

張貼留言