Why does setting connection string to BTSCatalogExplorer gives SetValueInvocationException when the values are correct? RRS feed

  • Question

  • I need to Stop a BizTalk Application via Powershell remote session using BTSCatalogExplorer. I am able to get the dbserver and db name using WMI, but when I try to set the connection string to BTSCatalogExplorer, I get SetValueInvocationException.

    Exception setting "ConnectionString": "Error in the application."At line:1 char:1+ $btsCatalog.ConnectionString ="server=MYServer;database=BizTalkMgmtDb;Integra ...+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~    + CategoryInfo          : NotSpecified: (:) [], SetValueInvocationExceptio   n    + FullyQualifiedErrorId : ExceptionWhenSetting

    Following is my code-

    $group = Get-WmiObject MSBTS_GroupSetting -n root\MicrosoftBizTalkServer
    $grpsvr = $group.MgmtDBServerName
    $grpdb = $group.MgmtDBName
    $conStr = [System.String]::Concat("server=", $grpsvr, ";database=", $grpdb, ";Integrated Security=SSPI")	
    Write-Output "BizTalk CatalogExplorer Connection String : " $conStr
    $btsCatalog = New-Object Microsoft.BizTalk.ExplorerOM.BtsCatalogExplorer	
    $btsCatalog.ConnectionString = $conStr
    $esbApp = $btsCatalog.Applications['MyBizTalkApp']


    Actually the problem occurs when I execute these commands using a second user I added. although the user is added as an administrator in the server.

    • Edited by KJulian2 Friday, March 20, 2015 11:32 AM
    Friday, March 20, 2015 11:20 AM


  • Check the permissions of Second user against the User for which it is running fine.

    It will be great if you can give below privileges to user and try again

    BizTalk Server Administrator, SSO Administrator, SSO Affiliates Administrator and SysAdmin on SQL Server .

    It seems to be a permission issue only.

    Please mark this post accordingly if it answers your query or is helpful.

    • Marked as answer by Angie Xu Thursday, March 26, 2015 3:11 AM
    Friday, March 20, 2015 4:12 PM