none
NotImplementedException: Unmanaged activation is not supported RRS feed

  • Question

  • I'm getting the error NotImplementedException: Unmanaged activation is not supported

    The error is caused by the System function GetTypeFromProgIDImpl

    System.RuntimeType.GetTypeFromProgIDImpl (System.String progID, System.String server, System.Boolean throwOnError

    Called by

    System.Type type = System.Type.GetTypeFromProgID(progID, hostName, true);

    This exception is not thrown when the script is running as Windows Console app but it does it running on Unity. What could cause this different behaviour?

    This is a simple code that is throwing this exception in Unity but not in Cmd Prompt:

    //using UnityEngine;
    using System;
     
    public string pid = "VisualStudio.DTE.15.0";
    public string hostName = "localhost";
     
    public void executeSysFunc(){
             System.Type type = System.Type.GetTypeFromProgID(pid, hostName, true);
             Console.WriteLine(type.GUID);
             //Debug.Log(type.GUID);
    }


    • Moved by CoolDadTx Thursday, March 21, 2019 6:01 PM Third party product
    Thursday, March 21, 2019 3:15 PM

All replies

  • This is really a question for the Unity team, not C#. Unity runs its own version of .NET that (up until recently) was a CLR v2 version based on Mono I believe. Please post your question in their forums.

    Michael Taylor http://www.michaeltaylorp3.net

    Thursday, March 21, 2019 6:01 PM