Set-PWFolderWorkflow or Set-PWWorkflowByFolderPath Throwing error and not attaching workflow

I'm trying to attach a workflow to a folder.

I can attach it manually from the  settings dialog ( so I think the Folder and the Workflow are working)

when I try to use "Set-PWFolderWorkflow" (or "Set-PWWorkflowByFolderPath")

the CMDlet is erroring out:

WARNING: Failed to set the workflow for folder 'MiFiles'. ErrorID: 56046
WARNING: Failed to set workflow for 'MiFiles'.

56046 -  "Could not find the specified table in the database"

the code I am using goes like this:

#========================================================================

$TargetPath = "Lansing Support\biggarr\MiFiles"
$NewWorkflow = "Act51 - Submittals"

write-Host "Reading Target Folder..."
if ($PWfolder = Get-PWFolders -FolderPath $TargetPath -JustOne)
{
      Set-PWFolderWorkflow -InputFolder $PWfolder -NewWorkflow 'Act51 - Submittals' -Verbose
}
else
{
      write-Host "Target Folder NOT found..."
}

#=========================================================================

Not a lot of detail to these CMDlets....

Can anyone see anything I may be off track on?

Thank You, I appreciate it.

Bob

Parents Reply Children
No Data