Can't Stop Warning even after adding Import-Module

I am doing what the warning suggests, but I still get the warning.

Any idea how I can get this to stop?

I did add the xPSDesiredStateConfiguration instead of the PSDesiredStateConfiguration, I thought I would want the newest code to work with the configuration, but it seems I am missing something.

PS C:\> Configuration SimpleDSC
        param ( $NodeName )
        Import-DscResource –ModuleName 'xPSDesiredStateConfiguration'
        Node $NodeName
            WindowsFeature WebBackup
                    Ensure = "Present"
                    Name = "Windows-Server-Backup"

$nDir = mkdir C:\DSC\SimpleConfig\$Computer -Force

SimpleDSC -OutputPath $nDir.FullName -NodeName $Computer -Verbose
WARNING: The configuration 'SimpleDSC' is loading one or more built-in resources without explicitly importing associated modules. Add Import-DscResource –ModuleName
 'PSDesiredStateConfiguration' to your configuration to avoid this message.

    Directory: C:\DSC\SimpleConfig\cho3w9wb24

Mode                LastWriteTime         Length Name                                                                                                              
----                -------------         ------ ----                                                                                                              
-a----        3/22/2016   2:23 AM           1898 cho3w9wb24.mof <\pre>

Usualy this means there’s something wrong with your $env:PSMosulePath.

Nothing in your script requires xPSDesiredStateConfiguration, so no need to add it.

The warning says you should import PSDesiredStateConfiguration, not xPSDesiredStateConfiguration. :slight_smile: No “x”.