Microsoft® Visual Basic® Scripting Edition IsArray, fonction |
Référence du langage Version 1 |
Description
Renvoie une valeur booléenne indiquant si la variable est un tableau.
Syntaxe
IsArray(varname)L'argument varname représente toute variable.
Notes
La fonction IsArray renvoie la valeur True si la variable est un tableau si tel n'est pas le cas, elle renvoie la valeur False. La fonction IsArray est particulièrement utile avec des variants contenant des tableaux.L'exemple ci-dessous utilise la fonction IsArray pour tester si MyVariable est un tableau :
Dim MyVariable Dim MyArray(3) MyArray(0) = "Dimanche" MyArray(1) = "Lundi" MyArray(2) = "Mardi" MyVariable = IsArray(MyArray) ' MyVariable contient "True".