close

I need to scramble the letters in a long list of names (i.e., from mary to
yamr). Does anyone know a way to do that?
Thank you

Try this UDF:

name in A1

this in B1

=scramble(a1)

Function Scramble(oldname)
n = Len(oldname)

newname = quot;quot;
Do
i = Int(Rnd() * n) 1
c = Mid(oldname, i, 1)
If c lt;gt; quot;*quot; Then
newname = newname amp; c
oldname = Replace(oldname, c, quot;*quot;, , 1)
End If
Loop Until Len(newname) = n

Scramble = LCase(newname)

End Function

quot;SusanBquot; wrote:

gt; I need to scramble the letters in a long list of names (i.e., from mary to
gt; yamr). Does anyone know a way to do that?
gt; Thank you

arrow
arrow
    全站熱搜
    創作者介紹
    創作者 software 的頭像
    software

    software

    software 發表在 痞客邦 留言(0) 人氣()