// string of_ReplaceAll
// string as_source : 目標字串
// string as_old_str : 要取代的字串
// string as_new_str : 取代為
// 用 as_old_str 於 as_source 裏找尋,如符合,改為 as_new_str
long ll_pos, ll_start, ll_get_len
string ls_retval
//Pos ( string1, string2 {, start } )
ll_start=1
ll_pos = pos( as_source, as_old_str, ll_start)
ls_retval=''
do while ll_pos>0
ll_get_len = ll_pos - ll_start
ls_retval += Mid(as_source, ll_start, ll_get_len)
ls_retval += as_new_str
ll_start = ll_pos + Len(as_old_str)
ll_pos = pos( as_source, as_old_str, ll_start)
loop
ls_retval += Mid(as_source, ll_start)
Return ls_retval
没有合适的资源?快使用搜索试试~ 我知道了~
PB_ReplaceAll

共2个文件
jpg:1个
txt:1个


温馨提示
将一段文字中的字符串全部替换 PowerBuilder ReplaceAll
资源推荐
资源详情
资源评论
















收起资源包目录



共 2 条
- 1
资源评论

- the7thsense2022-06-20就这!你也好意思收50分,穷疯了吧 long ll_pos, ll_start, ll_get_len string ls_retval //Pos ( string1, string2 {, start } ) ll_start=1 ll_pos = pos( as_source, as_old_str, ll_start) ls_retval='' do while ll_pos>0 ll_get_len = ll_pos - ll_start ls_retval += Mid(as_source, ll_start, ll_get_len) ls_retval += as_new_str ll_start = ll_pos + Len(as_old_str) ll_pos = pos( as_source, as_old_str, ll_start) loop ls_retval += Mid(as_source, ll_start) Return ls_retval
- dgzys07692013-01-02没什么特别的啊,这代码早就写过了

eclat2299
- 粉丝: 16
- 资源: 5
上传资源 快速赚钱
我的内容管理 展开
我的资源 快来上传第一个资源
我的收益
登录查看自己的收益我的积分 登录查看自己的积分
我的C币 登录后查看C币余额
我的收藏
我的下载
下载帮助


安全验证
文档复制为VIP权益,开通VIP直接复制
