Hi,
I was wondering if I can use array indexing in NCM? Something along these lines:
script l2vlanscript (
NCM.Nodes @ContextNode,
string[] @vlanIDs,
string[] @vlanNAMEs
)
{
int @i=0
foreach (@vlanID in @vlanIDs)
{
@i=@i+1
}
// Enter configuration mode
CLI
{
configure terminal
}
int @j
// Loop through the VLAN IDs
for(@j=1; @j<=@i; @j=@j+1)
{
CLI
{
vlan @vlanIDs[@j]
name @vlanNAMEs[@j]
exit
}
}