I'm trying to add list items in a simple site.. but keep getting Invalid file name error:
See original GitHub issueI’m trying to add list items in a simple site… but keep getting Invalid file name error:
$batch = New-PnPBatch
Add-PnPListItem -List $list -Values @{"Title" ="site1"} -Batch $batch
Add-PnPListItem -List $list -Values @{"Title" ="site2"} -Batch $batch
Add-PnPListItem -List $list -Values @{"Title" ="site3"} -Batch $batch
$details= Invoke-PnPBatch -Batch $batch -Details
results in
Invalid file name. The file name you specified could not be used. It may be the name of an existing file or directory, or you may not have permission to access the file.
I’m using
Manifest 1.2.0 PnP.PowerShell
Tested with nightly build as well:
Manifest 1.2.7 PnP.PowerShell
Note: it works if I remove the batching.
_Originally posted by @bhishma in https://github.com/pnp/powershell/discussions/195_
Issue Analytics
- State:
- Created 3 years ago
- Comments:34 (16 by maintainers)
Top Results From Across the Web
I'm trying to add list items in a simple site.. but keep getting ...
I'm trying to add list items in a simple site.. but keep getting Invalid file name error: $batch = New-PnPBatch Add-PnPListItem -List $list ......
Read more >"Invalid file name" error creating folder programmatically
It may be the name of an existing file or directory, or you may not have permission to access the file. I am...
Read more >invalid file name error when saving to OneDrive
I am getting the same "invalid file name" error that others have posted about when trying to save a Word document to OneDrive....
Read more >"File Name Not Valid" Python Tkinter
I'm making a simple text editor and whenever I try to save a file it always gives me this error. enter image description...
Read more >Invalid Syntax in Python: Common Reasons for SyntaxError
Python will attempt to help you determine where the invalid syntax is in your code, but the traceback it provides can be a...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@DaleyKD : thanks for helping out and creating the PR @ollimenzel / @rtonerii : I’ve merged the PR from @DaleyKD , this will be included in the tomorrow’s nightly build from PnP PS, so would recommend giving that a try and let us know.
@ollimenzel : That root Site Collection was definitely the piece I was missing. I don’t know if that’s the same issue for @rtonerii or not. I’ve submitted a PR and will see if it’s accepted by @jansenbe .