0

So, I'm trying to create a script to help my team with the creation of application packages, so that things are a little quicker, and more cookie cutter with fewer little differences between application configs. I have most of it seemingly working, but I'm running into an issue with Add-CMScriptDeploymentType and the -ContentFallback parameter. Basically, I'm getting the following error:

Add-CMScriptDeploymentType : A positional parameter cannot be found that accepts argument 'True'. At C:\Users\User\Documents\New-MECMApplication.ps1:22 char:1 Add-CMScriptDeploymentType -ApplicationName $ApplicationName -Deploym ...

CategoryInfo : InvalidArgument: (:) [Add-CMScriptDeploymentType], ParameterBindingException FullyQualifiedErrorId : PositionalParameterNotFound,Microsoft.ConfigurationManagement.PowerShell.Cmdlets.AppMan.AddScriptDeploymentType

And here is the command itself that it's erroring from:

Add-CMScriptDeploymentType -ApplicationName $ApplicationName -DeploymentTypeName DT_Script_Npp -InstallCommand $InstallString -UninstallCommand $UninstallString -AddDetectionClause $clause -ContentLocation $ContentPath -InstallationBehaviorType InstallForSystem -MaximumRuntimeMins 30 -LogonRequirementType WhetherOrNotUserLoggedOn -ContentFallback $true -SlowNetworkDeploymentMode Download

Now, according to the documentation for this cmdlet, it LOOKS like I should be using $true for the value of -ContentFallback when I want that option enabled.

If you set this parameter to $true, when the content isn't available on any distribution points in the client's current or neighbor boundary groups, the client can use distribution points in the site default boundary group.

But apparently I'm doing it wrong or something? Any ideas?

1 Answer 1

0

Thanks to a knowledgeable person on Reddit, I have the answer. Apparently even though the documentation suggests this parameter needs an answer, it doesn't. Just adding -ContentFallBack is enough to enable the functionality. I just tested it and it worked as expected.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.