Deltas/Get-NAVCustomObjectVersion.ps1

function Get-NAVCustomObjectVersion
{
    Param(
    [Parameter(Mandatory=$true)]
    [string]$ObjectFilePath    
    )

    $CustomVersions = @()

    [string]$ObjectVersion = Get-NAVObjectVersion -ObjectFilePath $ObjectFilePath
    $ObjectVersions = $ObjectVersion.Split(',')
    foreach ($ObjectVersion in $ObjectVersions)
    {
        [boolean]$IncludeVersion = $true
        $StandardObjectPrefixes = Get-StandardObjectPrefixes
        foreach ($Prefix in $StandardObjectPrefixes)
        {
            if ($ObjectVersion.StartsWith($Prefix))
            {
                $IncludeVersion = $false
            }
        }

        if ($IncludeVersion)
        {
            $CustomVersions += $ObjectVersion
        }
    }

    [String]::Join(',',$CustomVersions)
}

Export-ModuleMember -Function Get-NAVCustomObjectVersion