Am I missing something? (execute powershell script)

Whenever I use the script editor for any action (BeforeAction,AfterAction), I can easily get/set variables by using for example $FBVariables.GetVariable("somevariable")

If I use the execute powershell script action and specify the script text, I am unable to access variables using the same method as above.  I realize I can partially get around this by passing variable parameters in the options tab of the action setup, but how would I set variables?

Is there a reason I can't access get/set variable the regular way?  I am hoping its possible I am just doing something wrong.  I don't know a great deal about powershell

Thanks

The Powershell Action actually runs powershell.exe, so it doesn’t have access to $FBVariables. Use the Execute Script Action, and set the script language to Powershell. Then you will have access to $FBVariables (which btw is a collection, so you can do stuff like $blah = $FBVariables[“blah”] ).

thanks. I was not aware of that.