I am trying to update a Command and some of the information that it needs to function needs to be pulled from a couple of Functions. The Command and one of the Functions are custom items written by NetApp PS, and the other Function is a custom function that I wrote. While I cannot include the source here due to company policy, I can provide code fragments that might help you to diagnose the issue. The error message that I receive is “The term 'nextRuleClientMatch' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.”. A fragment of the Command code looks like this:
$message += @"
*) Add new netgroups to netgroup file
+) $(nextRuleClientMatch(2,$($splitText[1]),$($splitText[2]),$($splitText[6])))
+) $(nextRuleClientMatch(3,$($splitText[1]),$($splitText[2]),$($splitText[6])))
+) $(nextRuleClientMatch(4,$($splitText[1]),$($splitText[2]),$($splitText[6])))
*) Make sure netgroups are not empty, this can break all NFS access. If there are no servers, add ADMIN_PROD
"@
According to the error message, I should be able to call Functions from a Command. I have not been able to locate any documentation on coding in WFA, so all I can do it assume and base new code code on existing examples. If there is any decent documentation on coding in WFA, please point me to it. I'd be so happy to read it!
Update: I am using WFA 2.1, looking forward to 2.2GA!
Thanks,
Scott L