*edit: I must have been doing something wrong. I was getting no helpful information from this node: $psise.CurrentPowerShellTab.ConsolePane. Yet when I explored this using Raimund AndrÃ©e’s VariableExplorer, the info was there. Thanks anyhow!
I’m looking to customize my ISE a bit. One piece I’m missing is the ability to extract text and contextual information from the console pane. For example, if I’ve typed up a command but have not executed it yet, I want to click a function and take action based on that function (similar to how F1 opens help in a window). I can use code to do this for the editor pane from this handy post.
I’ve tried writing a scriptblock to serialize $psise, putting in some random commands in the PowerShell pane, and pressing the shortcut to the scriptblock… I don’t see anything in the resulting object that resembles the commands I had typed up.
I’m assuming that this is possible, and that F1 uses the same functionality to open help for a command…
Your insight would be greatly appreciated!