Sunday, June 25, 2017   Login
You are here: Project » Blog  
Looks like the C# IWeb method will not work :(
Location: BlogsIWeb    
Posted by: Michael Washington 3/16/2008 5:13 PM

I had hoped to allow you to create your IWeb methods in C#. My early prototypes seemed to work but I devoted most of the day trying and I can't get it to work.

Basically I created a C# IWebCF Method:

 
 
    public partial class CoreService : IWebCoreService
    {
        [WebMethod(Description = "Sample CSharp method")]
        [IWebMethod(
                Company = "DotNetNuke",
                Application = "IWeb",
                Name = "HelloCSharp",
                Description = "Sample CSharp method",
                Group1 = "General", Group2 = "Portal",
                DefaultSecuritySetting = IWebMethodAttribute.MethodSecurityLevels.Host)]
        public string HelloCSharp(IWebRequest msg)
        {
            return "Hello World!";
        }
    }
 
But it wont compile:
 
The type 'DotNetNuke.Modules.IWebCF.CoreService' is ambiguous: it could come from assembly 'C:\Windows\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\website\afc2ba2b\818728a9\App_SubCode_IWebCsharpExample.xzp4xtqn.DLL' or from assembly 'C:\Windows\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\website\afc2ba2b\818728a9\App_SubCode_IWebCF.kzydr_1l.DLL'. Please specify the assembly explicitly in the type name.
Permalink |  Trackback

Comments (1)  
Re: Looks like the C# IWeb method will not work :(    By williamgeorge on 3/3/2009 1:35 AM
Ya sure I think it wont work and it wont compile because of host structure will be failed.
--------
george
temping work in london

  
Home  |  Screen Shots  |  Example Code  |  Installing  |  Download  |  Project
Copyright 2006-2009 by OpenLightGroup.net   |  Privacy Statement  |  Terms Of Use