以文本方式查看主题

-  金字塔客服中心 - 专业程序化交易软件提供商  (http://weistock.com/bbs/index.asp)
--  高级功能研发区  (http://weistock.com/bbs/list.asp?boardid=5)
----  VBA的字符串数组问题  (http://weistock.com/bbs/dispbbs.asp?boardid=5&id=148052)

--  作者:550074
--  发布时间:2017/2/22 11:42:49
--  VBA的字符串数组问题

fa  = Split(formulas,",")

fa(0),fa(1)等固定坐标可以取到值

 

下面的For循环执行报错,应该怎么写?

 

for i=0 to fa.Length-1

   msgout  fa(i)

next


--  作者:王锋
--  发布时间:2017/2/22 14:36:20
--  

vbs不支持这种fa.Length-1的吧,

 

mydd = UBound(fa)

for i=0 to mydd

   msgout  fa(i)

next


--  作者:550074
--  发布时间:2017/2/23 9:24:46
--  
管用,谢谢!