This command is used to set the current folder. The folder must exist, otherwise the function produces an error. This is a way around this error:
:example() :Prgm :Try :setFold(fold1) :Else :ClrErr :NewFold(fold1) :EndTry
If you are changing the current folder, but want to set it back later, the getFold() command is not required to store the old folder name.
:foldset() :Prgm :Local a :getFold()→a :setFold(fold1) ... :setFold(#a) :EndPrgm
does the same thing as
:foldset2() :Prgm :Local a :setFold(fold1)→a ... :setFold(#a) :EndPrgm
420 - Invalid Folder Name happens when the folder does not exist.