How to create a boolean from an array. I have an array variable. This array list contains 5 hotspot user names that I will input each month at the beginning of each month. What I want to do is
if(the array names exist in /tool user-manager user) do={remove them all} else={create them and assign to a profile}. Easily I want to write that if those names exist, it will return true, and otherwise it will return false, so I can create them and assign to a profile. Please help..
Code: Select all
:local name
:set name "name1, name2, name3, name4, name5";
:if(/tool user-manager user $name) do={
/tool user-manager user remove $name
} else={
/tool user-manager user add username=$name password=$name customer=admin
/tool user-manager user create-and-activate-profile profile=800menit customer=admin
}