Page 2 of 3

Powershell cannot be instantiated

Posted: Mon Nov 28, 2011 5:34 am
by davidc
Interesting. I wonder if this is a permission issue. Does the packaged exe (without credentials) work if you log on as the impersonated user? David

Powershell cannot be instantiated

Posted: Mon Nov 28, 2011 7:15 am
by boyddt_co
good question, I'll give it a try. Why would it work within PrimalForms? is the impersonation not applicable at that time?David

Powershell cannot be instantiated

Posted: Mon Nov 28, 2011 7:42 am
by boyddt_co
David, I had the change to logon as iusr_domain which is the account specified in the build of the form. It ran as expected.

Powershell cannot be instantiated

Posted: Mon Nov 28, 2011 8:23 am
by davidc
I'm glad you were able to resolve the issue. FYI when you run a script inside PrimalForms, it runs as the current user, but you have the option to elevate if needed. David

Powershell cannot be instantiated

Posted: Mon Nov 28, 2011 8:28 am
by boyddt_co
David, the situation isn't solved. I can run it when I logon as iusr_domain but it still won't run using those credentials logged in as someone else. This little app is to be used by our helpdesk personnel who do not have the appropriate security rights to set folder permissions.

Powershell cannot be instantiated

Posted: Mon Nov 28, 2011 9:07 am
by davidc
Please try using "Run As" instead of "Impersonation". It may have to do with the fact that it is a domain user. David

Powershell cannot be instantiated

Posted: Mon Nov 28, 2011 9:08 am
by boyddt_co
from the start menu or something within PrimalForm

Powershell cannot be instantiated

Posted: Mon Nov 28, 2011 9:27 am
by davidc
It's a packager setting under the Security Tab. David

Powershell cannot be instantiated

Posted: Tue Nov 29, 2011 7:09 am
by boyddt_co
Ok, now I feel really fullish, no stupid. After testing different scenarios it turns out that I entered the password wrong. Which is interesting because I must have entered it 4 or 5 times in PrimalForms and I logged in with that account more than once.Well, thank you for your help and I'm sorry I wasted your time.

Powershell cannot be instantiated

Posted: Tue Mar 27, 2012 9:40 pm
by mssapien
I am experiencing the same problem. This is a new/blank forms project. I am quite sure I am not entering the wrong password.When choosing impersonate, the error message is: PowerShell cannot be instantiatedWhen choosing run as, the error message is: The directory name is invalidThe same error messages appear when I login as the impersonated/runas-ed user.
The username is entered in this form: username@domain.comI use PrimalForms 2011, Version 2.0.21 on a Windows 7 Enterprise x64 domain member machine.mssapien2012-03-28 04:42:21