0x80070057: The parameter is incorrect
A program or step got a value it could not use. In SCCM check the command line, the step settings and any variables that may be empty.
What 0x80070057 means
0x80070057 means "The parameter is incorrect". A program was called with a value it does not accept. The value may be empty, badly formed or out of range.
In SCCM you see it most often in smsts.log on a failed task sequence step. It can also show for an application in AppEnforce.log and in the console under Monitoring > Deployments.
Common causes
- A task sequence variable used in a step is empty or has the wrong value.
- A disk step targets a disk or partition that does not match the hardware.
- The install command has a bad switch, a missing quote or a path with spaces and no quotes.
- A script passes a wrong argument to a Windows tool or API.
How to fix 0x80070057
-
Find the step and its values
Open
smsts.logand search for "Failed to run the action". Note the step name. Read the lines above it. The log prints the command line and the values the step used. -
Check variables used by the step
Look for any variable in the step, written as
%Name%. Find where it is set: on the collection, on the device or in an earlier step. An empty variable leaves a gap in the command line.Add a Run Command Line step before the failed step to write the variables to a file. Use
cmd.exe /c setwith output sent to a text file, then read the file. -
Check disk steps against the hardware
If the failed step is Format and Partition Disk or Apply Operating System Image, check the disk number and the partition layout. Press F8 in Windows PE if command support is on in the boot image. Run
diskpart, thenlist disk, to see what the machine has. -
Check the quoting in the command line
For an application, open
AppEnforce.logand copy the command line. Put quotes around any path with spaces. Check each switch against the vendor's install guide. Then test the command as SYSTEM on a test machine.
Commands that help
cmd.exe /c set > C:\Windows\Temp\ts-variables.txt
Turn any hex or decimal error code into its meaning, or search every code on this site.