Problem with MOSSRadEditor base class in RadEditor for MOSS 4.5.6

10 posts, 0 answers
  1. Aj
    Aj avatar
    5 posts
    Member since:
    Sep 2006

    Posted 14 May 2009 Link to this post

    Hi,

    I downloaded the latest version of RadEditor for MOSS (version 4.5.6.0), but it broke my custom MOSS solution, because I can no longer create an instance of MOSSRadEditor in code. The error message is:

    The type 'Telerik.SharePoint.MOSSRadEditor' has no constuctors defined. 

    In previous version that we were using (4.5.4.0) the constructor was public, but now it has been changed to internal. Has it been deliberately changed and is there another way I should instantiate the MOSSRadEditor class now? The help file of this editor version still suggests that the old code should work.

    With regards,


    Antti
  2. Stanimir
    Admin
    Stanimir avatar
    1653 posts

    Posted 14 May 2009 Link to this post

    Hello Aj,

    Indeed, the old code should be working. So in order to help you we will need to reproduce the problem on our test server. Please provide us with your web.config, the configuration files of the RadEdtior for MOSS (ConfigFile.xml, ListConfigFile.xml, ToolsFile.xml, ListToolsFile.xml), which are located in the /Program Files/Common Files/Microsoft Shared/web server extensions/wpresources/RadEditorSharePoint/4.5.6.0__1f131a624888eeed/RadControls/Editor/ folder and a sample page where you are using the MOSSRadEditor.

    Thank you.

    All the best,
    Stanimir
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.

  3. Aj
    Aj avatar
    5 posts
    Member since:
    Sep 2006

    Posted 14 May 2009 Link to this post

    Hi,

    Ok, I can provide the sample code, but it's functionally similar to the sample in the help file:

    private MOSSRadEditor contentEditor; 
    protected override void CreateChildControls() 
       contentEditor = new MOSSRadEditor(); 
       contentEditor.Content = "Enter content..."
       base.CreateChildControls(); 
     
     

    The code complains already in Visual Studio that MOSSRadEditor has no constructors defined and I cannot build the project.

    When I look inside the RadEditorSharePoint assembly with Reflector I can see the reason; the constructor is internal, so I cannot call it. This has been changed from the previous RadEditor version, so I was wondering if the change is deliberate. Below is a snapshot of the Reflector disassembly.

    public class MOSSRadEditor : RadEditor 
        // Fields 
        private bool _allowExternalUrls; 
        private Color _editorBackgroundColor; 
        private int LCID; 
     
        // Methods 
        internal MOSSRadEditor(); 
     
    ... 
     
     


  4. Stanimir
    Admin
    Stanimir avatar
    1653 posts

    Posted 16 May 2009 Link to this post

    Hi Aj,

    I tried the provided code on our test server and it worked fine . In order to help you further I will need to reproduce the problem on our side. So please provide me with the required in my previous post information and any other means that you might think would be helpful in doing this.

    Thank you.


    Sincerely yours,
    Stanimir
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
  5. Aj
    Aj avatar
    5 posts
    Member since:
    Sep 2006

    Posted 18 May 2009 Link to this post

    Hello,

    It would be most useful if I sent you my whole Visual Studio solution with the referenced Telerik assemblies. Is there an e-mail address or an upload form I could use to do this?

    With regards,

    Antti
  6. Stanimir
    Admin
    Stanimir avatar
    1653 posts

    Posted 18 May 2009 Link to this post

    Hello Aj,

    You can try stanimir.patarinski@telerik.com. But I am not sure what is the size limit of the receiving files. You can upload the archive somewhere and send me an URL.


    All the best,
    Stanimir
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
  7. Stanimir
    Admin
    Stanimir avatar
    1653 posts

    Posted 18 May 2009 Link to this post

    Hello Aj,

    I received your email. What was wrong with your project is that you forgot to include the RadSpell.Net2.dll as well. I attached a fixed version of the project to this thread.


    Sincerely yours,
    Stanimir
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
  8. Aj
    Aj avatar
    5 posts
    Member since:
    Sep 2006

    Posted 18 May 2009 Link to this post

    Hello,

    Thanks for the code, it certainly works. But the reason it works is that you have replaced the RadEditorSharePoint.dll with another one that has a public constructor (yes, time stamps are identical, but the DLLs are different). The DLL that was in my sample project didn't have a public constructor. If you replace the RadEditorSharePoint.dll from your solution with the one in my solution, your project will not compile either. Can you please try this.

    I checked again the version that is available in my downloads (Home > Your account > Downloads / RadEditor MOSS Edition) and it still is the not-working one.

    Best regards,

    Antti
  9. Stanimir
    Admin
    Stanimir avatar
    1653 posts

    Posted 20 May 2009 Link to this post

    Hello Aj,

    I can see that you are using the Lite version of RadEditor for MOSS. One of the differences between the full and the lite version is that the light does not support any customizations and there is no public constructor for the MOSSRadEditor class.


    Kind regards,
    Stanimir
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
  10. Aj
    Aj avatar
    5 posts
    Member since:
    Sep 2006

    Posted 20 May 2009 Link to this post

    Hello,

    Indeed, this explains it. I need to recheck my subscription.

    Thanks for your help and patience.

    With regards,

    Antti
Back to Top