Function Remove-WUOfflineSync
        Unregister offline scaner service.
        Use Remove-WUOfflineSync to unregister Windows Update offline scan file ( or from current machine.
        Check if Offline Sync Service is registered and try unregister it.
        PS C:\> Remove-WUOfflineSync
        Are you sure you want to perform this action?
        Performing operation "Unregister Windows Update offline scan file" on Target "G1".
        [Y] Yes [A] Yes to All [N] No [L] No to All [S] Suspend [?] Help (default is "Y"): Y
        ServiceID IsManaged IsDefault Name
        --------- --------- --------- ----
        9482f4b4-e343-43b6-b170-9a65bc822c77 False False Windows Update
        7971f918-a847-4430-9279-4a52d1efe18d False False Microsoft Update
        3da21691-e39d-4da6-8a4b-b43877bcb1b7 True True Windows Server Update Service
        Author: Michal Gajda
        Blog :

        $User = [Security.Principal.WindowsIdentity]::GetCurrent()
        $Role = (New-Object Security.Principal.WindowsPrincipal $user).IsInRole([Security.Principal.WindowsBuiltinRole]::Administrator)

            Write-Warning "To perform some operations you must run an elevated Windows PowerShell console."    
        } #End If !$Role
        $objServiceManager = New-Object -ComObject "Microsoft.Update.ServiceManager"
        $State = 1
        Foreach ($objService in $objServiceManager.Services) 
            If($objService.Name -eq "Offline Sync Service")
                   If ($pscmdlet.ShouldProcess($Env:COMPUTERNAME,"Unregister Windows Update offline scan file")) 
                    } #End Try
                        If($_ -match "HRESULT: 0x80070005")
                            Write-Warning "Your security policy don't allow a non-administator identity to perform this task"
                        } #End If $_ -match "HRESULT: 0x80070005"
                            Write-Error $_
                        } #End Else $_ -match "HRESULT: 0x80070005"
                    } #End Catch
                } #End If $pscmdlet.ShouldProcess($Env:COMPUTERNAME,"Unregister Windows Update offline scan file")
                $State = 0;    
            } #End If $objService.Name -eq "Offline Sync Service"
        } #End Foreach $objService in $objServiceManager.Services
            Write-Warning "Offline Sync Service don't exist on current machine."
        } #End If $State
    } #End Process
} #In The End :)