html5/css教程

javascript教程

asp教程

php教程

jsp教程

C#/.NET教程

Python教程

网络营销

建站经验

点击排行

asp下去除数组中重复的元素项的方法

来源:中文源码网    浏览:421 次    日期:2024-04-15 17:23:39
Function MoveR(Rstr) 
Dim i,SpStr 
SpStr = Split(Rstr,",") 
For i = 0 To Ubound(Spstr) 
If I = 0 then 
MoveR = MoveR & SpStr(i) & "," 
Else 
If instr(MoveR,SpStr(i))=0 and i=Ubound(Spstr) Then 
MoveR = MoveR & SpStr(i) 
Elseif instr(MoveR,SpStr(i))=0 Then 
MoveR = MoveR & SpStr(i) & "," 
End If 
End If 
Next 
End Function 
response.write MoveR("abc,abc,dge,gcg,dge,gcg,die,dir,die")

精彩推荐