I've a need to change the "DisableFormatUpdates" session state value within my powershell. I've figured out how to retrieve the initial session state:
[System.Management.Automation.Runspaces.Runspace]::DefaultRunspace.InitialSessionState
DisableFormatUpdates : True
Which returns the value as expected.
However I don't understand how to set this value to False, so that I can complete an import of a module. It appears that the runspace is being set by SMA, but I need to reset this value for a module that we're required to load.
Any help would be appreciated, as I'm definitely out of my element on setting this within the context of my powershell workflow.