Microsoft Virtualization Discussions

Add-NcLunMap and Remove-NcLunMap always asks for confirmation

Andrew7193

I have a script that is being used in doing DR tests. It maps or removes the mapping depending on the stage of the test. When the Add-NcLunMap and the Remove-NcLunMap commands run there is a pop-up that asks if you are sure you want to do this. How do I get rid of that?

2 REPLIES 2

Re: Add-NcLunMap and Remove-NcLunMap always asks for confirmation

donny_lang

Add "-Confirm $false" to your commands, should suppress the confirmation dialog. 

View solution in original post

Re: Add-NcLunMap and Remove-NcLunMap always asks for confirmation

Andrew7193

-Confirm:$false cannot forget the ":". I found that out a bit ago and just now got a a chance to answer. 

Thank you.

Earn Rewards for Your Review!
GPI Review Banner
All Community Forums
Public