' Name: RandomHelloACM (By: ANmarAmdeen on 5/13/2018 9:07:00 PM) ' Language: Classic ASP | Category: Strings ' Tags: Random, ASP+PHP ' Parameters: Leng, Upper, Lower, Digits, SpcChars ' ' Attachments: 1 ' Link: http://MyDev.net/?DevID=S8SAGUMA2 ' ' Description: Generate random using web service into ASP variable.
With help of PHP, we now have another way to generate random strings, needed to create random ID for some of my web applications
Originally from https://helloacm.com/random/ ' Function RandomHelloACM(Leng, Upper, Lower, Digits, SpcChars) ' Leng is length of password ' Upper = 1 or 0 to include upper case ' Lower = 1 or 0 for lower case ' Digits = 1 or 0 for numeric digits ' SpcChars = 1 or 0 for special characters ' Attached file is the complete PHP that does generate that random ' XX = Upper + (Lower * 2) + (Digits * 4) + (SpcChars * 8) Set xmlhttp = CreateObject("MSXML2.ServerXMLHTTP") xmlhttp.open "GET", "http://MyDev.net/Assets/RandomHelloACM.php?n=" & Leng & "&x=" & XX, 0 ' n = number of characters ' x = bitmask ' 1 = upper case, 2 = lower case, 4 = digist, 8 = special chars ' x = 5 means = 1 + 4 = upper + digits xmlhttp.send "" RandomHelloACM = Replace(xmlhttp.responseText, """", "") Set xmlhttp = Nothing End Function

RandomHelloACM

Generate random using web service into ASP variable.
With help of PHP, we now have another way to generate random strings, needed to create random ID for some of my web applications
Originally from https://helloacm.com/random/

Function RandomHelloACM(Leng, Upper, Lower, Digits, SpcChars)
    ' Leng is length of password
    ' Upper = 1 or 0 to include upper case
    ' Lower = 1 or 0 for lower case
    ' Digits = 1 or 0 for numeric digits
    ' SpcChars = 1 or 0 for special characters
    ' Attached file is the complete PHP that does generate that random
    '
    XX                          = Upper + (Lower * 2) + (Digits * 4) + (SpcChars * 8)
    Set xmlhttp             = CreateObject("MSXML2.ServerXMLHTTP")
    xmlhttp.open "GET", "http://MyDev.net/Assets/RandomHelloACM.php?n=" & Leng & "&x=" & XX, 0
    '                            n = number of characters
    '                            x = bitmask
    '                                1 = upper case, 2 = lower case, 4 = digist, 8 = special chars
    '                                x = 5 means = 1 + 4 = upper + digits
    xmlhttp.send ""
    RandomHelloACM          = Replace(xmlhttp.responseText, """", "")
    Set xmlhttp             = Nothing
End Function

ANmarAmdeen
45
Tags
Random, ASP+PHP
Parameters
Leng, Upper, Lower, Digits, SpcChars
Strings Classic ASP