[唐胡璐]VBS技巧 Generate Random String(产生随机数)

 Function RandomString( ByVal strLen )     

    Dim str     
    Const LETTERS = "abcdefghijklmnopqrstuvwxyz0123456789"

    For i = 1to strLen      
        str = str & Mid( LETTERS, RandomNumber( 1, Len( LETTERS ) ), 1 )     
    Next     

    RandomString = str

EndFunction

原文地址:https://www.cnblogs.com/yongfeiuall/p/4134200.html