Search Unity

  1. Improved Prefab workflow (includes Nested Prefabs!), 2D isometric Tilemap and more! Get the 2018.3 Beta now.
    Dismiss Notice
  2. The Unity Pro & Visual Studio Professional Bundle gives you the tools you need to develop faster & collaborate more efficiently. Learn more.
    Dismiss Notice
  3. Let us know a bit about your interests, and if you'd like to become more directly involved. Take our survey!
    Dismiss Notice
  4. Improve your Unity skills with a certified instructor in a private, interactive classroom. Watch the overview now.
    Dismiss Notice
  5. Want to see the most recent patch releases? Take a peek at the patch release page.
    Dismiss Notice

CSharpCodeProvider throws a TypeException in Builds

Discussion in 'Scripting' started by QFSW, Oct 13, 2018.

  1. QFSW

    QFSW

    Joined:
    Mar 24, 2015
    Posts:
    2,220
    Hi, I'm using CSharpCodeProvider and CodeDom to provide runtime compilation support to a console. In the windows editor, 2018.2 +. NET 4 this works perfectly fine. In a Mono build however, it fails to work. It looks for the mono .exe in a strange non existent path. (if my build was at a/b/c/build, it looks for it in a/b/mono.../ etc) and throws an exception.

    I have a few questions:
    A) Is CSharpCodeProvider only supported on Windows or on other platforms too?
    B) Why is it failing in the build?
    C) How can this be fixed or circumvented?

    Thanks
     
  2. LurkingNinjaDev

    LurkingNinjaDev

    Joined:
    Jan 20, 2015
    Posts:
    830
  3. QFSW

    QFSW

    Joined:
    Mar 24, 2015
    Posts:
    2,220