remoting -- control embedded in IE

Hi,

I am trying to use .NET remoting in forms control, I just declared:

-------------------------------------------------
using System.Runtime.Remoting;
using System.Runtime.Remoting.Channels;
using System.Runtime.Remoting.Channels.Http;

namespace WindowsControlLibrary1
{

    public class UserControl1 : System.Windows.Forms.UserControl 
{
     HttpClientChannel channel = new HttpClientChannel ();
...
}

------------------------------------------------

and my forms control can not be displayed in the IE, any idea  Thanks


Mimi


Answer this question

remoting -- control embedded in IE

  • Josh Gammon

    Hi Mimi

    Another strange effect we had that looks like your problem, that a WindowsControlLibrary.dll.config file must be present. Even if no content for remoting is included - it was loading our controls after creating one.

    You must reference this config file in der header section of your HTML like
    <link rel="configuration" href="WindowsControlLibrary.dll.config" />

    Maybe this helps,
    Markus Leder

  • dotnetat43

    We had problems with remoting until we added the <link> tag which you describe above. What we can not do is place the config file in another path like "./config_files/MyDll.dll.config" or in a plain URL like http://server/config_files/MyDll.dll.config.

    Our problem is that we must host our controls in SharePoint 2007 so it seems like we need a URL like href link. Has anybody hosted user controls with remoting in SharePoint (any version)

    Cheers

    Julius



  • OSIGeoff

    To use any of the Classes, Enums (etc.) that are contained in the System.Runtime.Remoting.dll the caller must have FullTrust.  Unfortunately, you won't have the FullTrust Permission Set without modification of some Code Access Group(s) or their related Permission Sets (head to the .NET Configuration tool in the Control Panel).
  • Mr. Mike B

    I guess you must be having SecurityException or the User Control did not appear in the Page. You need to grant certain permissions to the User control to use .NET remoting in client side.
  • remoting -- control embedded in IE