I have a list of items on a powershell GUI, when I clic one, I call the same runspace $runspace.BeginInvoke()
But if I click on quickly the first instance is in progress for the second item. I Stop it ($runspace.stop()
and $runspace.dispose()
) berore recall my runspace.
but sometimes my GUI fail between Stop()
and dispose()
. I can only assume that this method is not good