Options

Executing Dynamics NAV PowerShell scripts from C#

mbjmbj Member Posts: 63
edited 2014-10-22 in NAV Three Tier
New-NAVServerInstance fails when calling from C#

I have a problem with Executing Dynamics NAV PowerShell scripts directly from C#.
New-NAVServerInstance fails from C# with the error: Unable to locate the default ServerInstane

When invoking directly from ISE the Script works just fine?

Any suggestion?

Comments

  • Options
    thegunzothegunzo Member Posts: 274
    Are you running from C# in elevated permission mode ? Like when you run the ISE as Administrator ?
    ________________________________
    Gunnar Gestsson
    Microsoft Certified IT Professional
    Dynamics NAV MVP
    http://www.dynamics.is
    http://Objects4NAV.com
  • Options
    mbjmbj Member Posts: 63
    Yes, I'm running my C# code in elevated permission mode.
Sign In or Register to comment.