Hi,
Posting here instead of Product Groups.
I have been trying to use Remove-IshPublicationOutput -IshObject $ishObjects -Force and find that it is only successful if the publication has been published but how do I remove a publication object that does not have an associated output object with it?
Now I am also trying to remove the topics from the topics folder as follows:
$topicsFolderPath = 'General\Import\Topics'
$topicsFolder = Get-IshFolder -IShSession $ishSession -FolderPath $topicsFolderPath
$ishObjects = Get-IshFolderContent -IShSession $ishSession -IshFolder $topicsFolder
if($ishObjects.length -gt 0)
{
foreach($ishObject in $ishObjects)
{
Remove-IshDocumentObj -IShSession $ishSession -IshObject $ishObjects -Force
}
}
but I am getting the following error on the call to Remove-IshDocumentObj
Remove-IshDocumentObj : Cannot convert 'System.Object[]' to the type 'Trisoft.ISHRemote.Objects.Public.IshObject' required by parameter
'IshObject'. Specified method is not supported.
At <path>\CleanScript.ps1:60 char:63
+ ... -IshDocumentObj -IShSession $ishSession -IshObject $ishObjects -Force
+ ~~~~~~~~~~~
+ CategoryInfo : InvalidArgument: (:) [Remove-IshDocumentObj], ParameterBindingException
+ FullyQualifiedErrorId : CannotConvertArgument,Trisoft.ISHRemote.Cmdlets.DocumentObj.RemoveIshDocumentObj
Any advice appreciated,
Regards,
Ann