Fonction IsArray VBScript

La fonction IsArray renvoie une valeur booléenne qui indique si la variable d'entrée spécifiée est une variable de tableau.

Syntaxe

IsArray(variablename)

Exemple

<!DOCTYPE html>
<html>
   <body>
      <script language = "vbscript" type = "text/vbscript">
         a = array("Red","Blue","Yellow")
         b = "12345"

         Document.write("The IsArray result 1 : " & IsArray(a) & "<br />")
         Document.write("The IsArray result 2 : " & IsArray(b) & "<br />")

      </script>
   </body>
</html>

Lorsque le code ci-dessus est enregistré au format .HTML et exécuté dans Internet Explorer, il produit le résultat suivant:

The IsArray result 1 : True
The IsArray result 2 : False