Invoke powershell activity error

Invoke Power Shell: The term ‘export-fimconfig’ 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.

Hi @kalbhorpriyanka0
welcome to forum
can u check whether the word is cmdlet or not

also can u share the screeshot of powershell script which u are using

hi @Nived,
yes the word is cmdlet used in FIM application.

The script i am using is as follows:
function GetAttribute
PARAM($exportObject,[string] $name)
$attribute = exportObject.ResourceManagementObject.ResourceManagementAttributes | Where-Object {_.AttributeName -eq $name}
if ($attribute -ne $null -and $attribute.Value -ne $null) {
elseif($attribute -ne $null -and $attribute.Values -ne $null)

if(@(get-pssnapin | where-object {$_.Name -eq “FIMAutomation”} ).count -eq 0) {add-pssnapin FIMAutomation}
#$url = “http://localhost:5725/ResourceManagementService
#$url = “
$url = “
$date = $null
$level = $null
$filter2 = “/Person[AccountName = pkalbhor]”
$users = export-fimconfig -onlyBaseResources -uri $url -customconfig ($filter2) -ErrorVariable Err -ErrorAction SilentlyContinue
$GPOLevel = GetAttribute $users “_GroupPolicyLevel”
Write-Host $GPOLevel
return $GPOLevel
$GPOExpiryDate = GetAttribute $users “GPOexpiryDate”
Write-Host $GPOExpiryDate
return $GPOExpiryDate
if($GPOLevel -ne $level)
#setting the value for gpo level along with date
elseif($GPOLevel -eq $level){
#set the date only