Dynamic Assembly

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • web1110

    #1

    Dynamic Assembly

    Hi y'all,

    I was playing with the ability to dynamically create an assembly.

    I created a windows application in which I created a CSharp program in a
    disk file, compiled it etc. My problem is that the dll calls
    MessageBox.Show () and this is causing errors in the compilation.

    What I need to know is what assemblies must I employ (via 'using' and
    CompilerParamet ers.ReferencedA ssemblies.Add() ) to permit a dynamically
    created dll to call MessageBox.Show ()?

    Thanx,
    Bill

    PS If 'using System;' references 'system.dll'
    Does 'using qqq;' reference 'qqq.dll'?
    What about 'using AAA.BBB.CCC'? Can I infer a dll name from the using
    specification?


  • Mattias Sjögren

    #2
    Re: Dynamic Assembly

    Bill,
    [color=blue]
    >What I need to know is what assemblies must I employ (via 'using' and
    >CompilerParame ters.Referenced Assemblies.Add( )) to permit a dynamically
    >created dll to call MessageBox.Show ()?[/color]

    The MessageBox class is implemented in the System.Windows. Forms
    assembly.

    [color=blue]
    >PS If 'using System;' references 'system.dll'
    > Does 'using qqq;' reference 'qqq.dll'?[/color]

    No, assemblies and namespaces are different things, though they tend
    to have similar names.

    [color=blue]
    > What about 'using AAA.BBB.CCC'? Can I infer a dll name from the using
    >specificatio n?[/color]

    No, the AAA.BBB.CCC namespace can be implemented in any number of
    assemblies.



    Mattias

    --
    Mattias Sjögren [MVP] mattias @ mvps.org

    Please reply only to the newsgroup.

    Comment

    Working...