More in this section

Forums / Developing with Sitefinity / Not able to find control templates.

Not able to find control templates.

17 posts, 0 answered
  1. Venkat
    Venkat avatar
    105 posts
    Registered:
    20 Nov 2008
    28 Apr 2009
    Link to this post


    I am using site finity 3.6 version .Here I want to customize the templates in the blogs module.

    I tried to find those templates but not able to find those.

    How can I add my logic to these predefined templates.

    For example , we are not using the category .so that I want to hide this category from the user.

    I want to create a user control for tags and wanted to place it on

    ~/Sitefinity/Admin/ControlTemplates/Blogs/ControlPanelInsert.ascx


    as I did in Sitefinity 3.5.

    but I am not able to find this template aswellas so many other templates.

    I think all these templates are moved into the dlls?

    Now How can I edit those templates?

    any one please help me.


  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    28 Apr 2009
    Link to this post
    Hi Venkat,

    You need to map the external templates which are shipped as zip archive form MyClient.net. The architecture from version 3.6 has been changed. You can gather more information at

    http://www.sitefinity.com/support/knowledge-base/kb-article/b1154K-bcge-b1154T-cgb.aspx

    http://blogs.sitefinity.com/Ivan/Posts/09-02-18/Sitefinity_3_6_new_backend_architecture_-_documentation_outline.aspx


    All the best,
    Ivan Dimitrov
    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. Venkat
    Venkat avatar
    105 posts
    Registered:
    20 Nov 2008
    29 Apr 2009
    Link to this post

    Hi Ivan,

    Thank you for your reply,It helped me a lot.I have one more question.

    The zip file Sitefinity_3_6_1920_standard_ExternalTemplates.zip

    does not contain the template for CommandPannel.ascx

    I need to customize that template too.

    How can I access/get  that template.

    Thanks
    Venkat.
  4. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    29 Apr 2009
    Link to this post
    Hi Venkat,

    There are several options if you want to make changes to the CommandPanel of any module. Since we use Views the situation is different in 3.6.
    First you need to override the desired module ControlPanel and then you can create your custom command panel.

    Here is a sample:

    using System; 
    using System.Collections.Generic; 
    using System.Linq; 
    using System.Web; 
    using Telerik.Events.WebControls.Admin; 
     
    /// <summary> 
    /// Summary description for CommandPanel 
    /// </summary> 
    public class MyCommandPanel : Telerik.Blogs.WebControls.Admin.BlogsControlPanel 
        public IvanCommandPanel() 
            : base(false
        { 
        } 
     
        protected override void CreateCommandPanelsFromUserControls(string viewMode, List<string> userControls, List<Telerik.Web.ICommandPanel> list) 
        { 
            //base.CreateCommandPanelsFromUserControls(viewMode, userControls, list); 
            if (userControls == null
                userControls = new List<string>(); 
     
            userControls.Add("~/MyControls/MyCommandPanel.ascx"); 
            base.CreateCommandPanelsFromUserControls(viewMode, userControls, list); 
        } 
     
        // second way 
        protected override void CreateCustomCommandPanels(string viewMode, List<Telerik.Web.ICommandPanel> list) 
        { 
            //base.CreateCustomCommandPanels(viewMode, list); 
        } 
     
        //third way 
        protected override void CreateStandardCommandPanels(string viewMode, List<Telerik.Cms.Web.UI.Backend.CommandItem> commandsInfo, List<Telerik.Web.ICommandPanel> list) 
        { 
            //base.CreateStandardCommandPanels(viewMode, commandsInfo, list); 
        } 
     

    For more information, please refer our temporary documentation

    Regards,
    Ivan Dimitrov
    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. Venkat
    Venkat avatar
    105 posts
    Registered:
    20 Nov 2008
    01 May 2009
    Link to this post

    Hi Ivan ,

    Thanks for your reply,I have one question,Where can I put this code?

    I think its a Custom control,So that how can  I incorporate this code into our application?

    Please give me more clarification.
  6. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    01 May 2009
    Link to this post
    Hi Venkat,

    You need to create a class in your App_Code folder, in this case called MyCommandPanel. This code will replace the whole command panel for the inherited module in the code below. The sample shows how to create CommandPanel from user control where I am adding ~/MyControls/MyCommandPanel.ascx

    Sincerely yours,
    Ivan Dimitrov
    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. Venkat
    Venkat avatar
    105 posts
    Registered:
    20 Nov 2008
    01 May 2009
    Link to this post

    Hi Ivan,

    I did as you said,

    Added this class under App_Code .

    changed the config file 

    Telerik.Sitefinity.Configuration.ControlsConfig.xml

    to load my Custom Command pannel.

    here is the code that I placed in the config file

    <

     

    viewSettings hostType="InsightsCommandPanel" layoutTemplatePath="~/Sitefinity/Admin/ControlTemplates/Blogs/CommandPanel.ascx" />

     

    added A user control under Blogs named as CommandPanel.ascx.<BR><BR>The   
    Class's&nbsp; code is&nbsp;<BR>

    protected override void CreateCommandPanelsFromUserControls(string viewMode, List<string> userControls, List<Telerik.Web.ICommandPanel> list)

     

    {

     

    //base.CreateCommandPanelsFromUserControls(viewMode, userControls, list);

     

     

     

     

     

    if (userControls == null)

     

    userControls =

    new List<string>();

     

     

    userControls.Add(

    "~/Sitefinity/Admin/ControlTemplates/Blogs/CommandPanel.ascx");

     

     

    base.CreateCommandPanelsFromUserControls(viewMode, userControls, list);

     

    }

     

    .
    But the Command panel in the Blog is diplaying the default values only not from the custom template.

    Thanks

    Venkat.

     

  8. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    01 May 2009
    Link to this post
    Hello Venkat,

    Your mapping is not correct.

    Sample:

      <viewSettings hostType="Telerik.Blogs.WebControls.Admin.BlogsControlPanel, Telerik.Blogs"
          <views> 
          <remove name="BlogsControlPanel"></remove> 
          <add name="MyCommandPanel" viewType="MyCommandPanel, App_Code"></add> 
          </views> 

    For more information please refer our outline documentation.

    Regards,
    Ivan Dimitrov
    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.
  9. Venkat
    Venkat avatar
    105 posts
    Registered:
    20 Nov 2008
    01 May 2009
    Link to this post

    Ivan ,

    The command panel I added is showing up in Control panel area.

    Here I am giving you the steps i did

    1)created a MyCommandPanel in App_Code.
    2)created a UserControl with the same name in Blogs folder.
    3)changed the Config file settings as given below

    <

     

    viewSettings hostType="Telerik.Blogs.WebControls.Admin.BlogsControlPanel, Telerik.Blogs" layoutTemplatePath="~/Sitefinity/Admin/ControlTemplates/Blogs/InsightsCommandPanel.ascx" />

     


    And here is the code written in MyCommandPanel.cs 

     

    1 <FONT color=#0000ff size=2><FONT color=#0000ff size=2>  
    2 <P>using</FONT></FONT><FONT size=2> System; </P></FONT><FONT color=#0000ff   
    3 size=2><FONT color=#0000ff size=2>  
    4 <P>using</FONT></FONT><FONT size=2> System.Collections.Generic; </P></FONT><FONT   
    5 color=#0000ff size=2><FONT color=#0000ff size=2>  
    6 <P>using</FONT></FONT><FONT size=2> System.Linq; </P></FONT><FONT color=#0000ff   
    7 size=2><FONT color=#0000ff size=2>  
    8 <P>using</FONT></FONT><FONT size=2> System.Web; </P></FONT><FONT color=#0000ff   
    9 size=2><FONT color=#0000ff size=2>  
    10 <P>using</FONT></FONT><FONT size=2> Telerik.Events.WebControls.Admin;   
    11 </P></FONT><FONT color=#808080 size=2><FONT color=#808080 size=2>  
    12 <P>///</FONT></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>   
    13 </FONT></FONT><FONT color=#808080 size=2><FONT color=#808080   
    14 size=2>&lt;summary&gt;</P> 
    15 <P>///</FONT></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>   
    16 Summary description for MyCommandPanel</P></FONT></FONT><FONT   
    17 color=#808080 size=2><FONT color=#808080 size=2>  
    18 <P>///</FONT></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>   
    19 </FONT></FONT><FONT color=#808080 size=2><FONT color=#808080   
    20 size=2>&lt;/summary&gt;</P></FONT></FONT><FONT color=#0000ff size=2><FONT   
    21 color=#0000ff size=2>  
    22 <P>public</FONT></FONT><FONT size=2</FONT><FONT color=#0000ff size=2><FONT   
    23 color=#0000ff size=2>class</FONT></FONT><FONT size=2</FONT><FONT color=#2b91af   
    24 size=2><FONT color=#2b91af size=2>MyCommandPanel</FONT></FONT><FONT   
    25 size=2>: Telerik.Blogs.WebControls.Admin.</FONT><FONT color=#2b91af size=2><FONT   
    26 color=#2b91af size=2>BlogsControlPanel</FONT></FONT><FONT size=2</P> 
    27 <P>{</P> 
    28 <P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    29 size=2>public</FONT></FONT><FONT size=2> InsightsCommandPanel() : </FONT><FONT   
    30 color=#0000ff size=2><FONT color=#0000ff size=2>base</FONT></FONT><FONT   
    31 size=2>(</FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    32 size=2>false</FONT></FONT><FONT size=2>) </P> 
    33 <P></P> 
    34 <P></P> 
    35 <P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    36 size=2>protected</FONT></FONT><FONT size=2</FONT><FONT color=#0000ff   
    37 size=2><FONT color=#0000ff size=2>override</FONT></FONT><FONT size=2>   
    38 </FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    39 size=2>void</FONT></FONT><FONT size=2>   
    40 CreateCommandPanelsFromUserControls(</FONT><FONT color=#0000ff size=2><FONT   
    41 color=#0000ff size=2>string</FONT></FONT><FONT size=2> viewMode, </FONT><FONT   
    42 color=#2b91af size=2><FONT color=#2b91af size=2>List</FONT></FONT><FONT   
    43 size=2>&lt;</FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    44 size=2>string</FONT></FONT><FONT size=2>&gt; userControls, </FONT><FONT   
    45 color=#2b91af size=2><FONT color=#2b91af size=2>List</FONT></FONT><FONT   
    46 size=2>&lt;Telerik.Web.</FONT><FONT color=#2b91af size=2><FONT color=#2b91af   
    47 size=2>ICommandPanel</FONT></FONT><FONT size=2>&gt; list) </P> 
    48 <P></P> 
    49 <P></FONT><FONT color=#008000 size=2><FONT color=#008000   
    50 size=2>//base.CreateCommandPanelsFromUserControls(viewMode, userControls, list);   
    51 </P></FONT></FONT><FONT size=2>  
    52 <P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    53 size=2>if</FONT></FONT><FONT size=2> (userControls == </FONT><FONT color=#0000ff   
    54 size=2><FONT color=#0000ff size=2>null</FONT></FONT><FONT size=2>) </P> 
    55 <P>userControls = </FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    56 size=2>new</FONT></FONT><FONT size=2</FONT><FONT color=#2b91af size=2><FONT   
    57 color=#2b91af size=2>List</FONT></FONT><FONT size=2>&lt;</FONT><FONT   
    58 color=#0000ff size=2><FONT color=#0000ff size=2>string</FONT></FONT><FONT   
    59 size=2>&gt;(); </P> 
    60 <P></P>  
    61 <P>userControls.Add(</FONT><FONT color=#a31515 size=2><FONT color=#a31515   
    62 size=2>"~/Sitefinity/Admin/ControlTemplates/Blogs/InsightsCommandPanel.ascx"</FONT></FONT><FONT   
    63 size=2>); </P> 
    64 <P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    65 size=2>base</FONT></FONT><FONT   
    66 size=2>.CreateCommandPanelsFromUserControls(viewMode, userControls, list); </P> 
    67 <P>}</P> 
    68 <P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>//public   
    69 override string CreateRootViewCommand(string param, string parentId, params   
    70 Type[] viewsChain)</P></FONT></FONT><FONT size=2>  
    71 <P></FONT><FONT color=#008000 size=2><FONT color=#008000   
    72 size=2>//{</P></FONT></FONT><FONT size=2>  
    73 <P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>// return   
    74 base.CreateRootViewCommand(param, parentId, viewsChain);</P></FONT></FONT><FONT   
    75 size=2>  
    76 <P></FONT><FONT color=#008000 size=2><FONT color=#008000   
    77 size=2>//}</P></FONT></FONT><FONT size=2>  
    78 <P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>//protected   
    79 override void InitializeControls(System.Web.UI.Control   
    80 container)</P></FONT></FONT><FONT size=2>  
    81 <P></FONT><FONT color=#008000 size=2><FONT color=#008000   
    82 size=2>//{</P></FONT></FONT><FONT size=2>  
    83 <P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>//   
    84 base.InitializeControls(container);</P></FONT></FONT><FONT size=2>  
    85 <P></FONT><FONT color=#008000 size=2><FONT color=#008000   
    86 size=2>//}</P></FONT></FONT><FONT size=2>  
    87 <P></P>  
    88 <P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>// second way   
    89 </P></FONT></FONT><FONT size=2>  
    90 <P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    91 size=2>protected</FONT></FONT><FONT size=2</FONT><FONT color=#0000ff   
    92 size=2><FONT color=#0000ff size=2>override</FONT></FONT><FONT size=2>   
    93 </FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    94 size=2>void</FONT></FONT><FONT size=2> CreateCustomCommandPanels(</FONT><FONT   
    95 color=#0000ff size=2><FONT color=#0000ff size=2>string</FONT></FONT><FONT   
    96 size=2> viewMode, </FONT><FONT color=#2b91af size=2><FONT color=#2b91af   
    97 size=2>List</FONT></FONT><FONT size=2>&lt;Telerik.Web.</FONT><FONT color=#2b91af   
    98 size=2><FONT color=#2b91af size=2>ICommandPanel</FONT></FONT><FONT size=2>&gt;   
    99 list) </P> 
    100 <P></P> 
    101 <P></FONT><FONT color=#008000 size=2><FONT color=#008000   
    102 size=2>//base.CreateCustomCommandPanels(viewMode, list); </P></FONT></FONT><FONT   
    103 size=2>  
    104 <P></P> 
    105 <P></P>  
    106 <P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>//third way   
    107 </P></FONT></FONT><FONT size=2>  
    108 <P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    109 size=2>protected</FONT></FONT><FONT size=2</FONT><FONT color=#0000ff   
    110 size=2><FONT color=#0000ff size=2>override</FONT></FONT><FONT size=2>   
    111 </FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    112 size=2>void</FONT></FONT><FONT size=2> CreateStandardCommandPanels(</FONT><FONT   
    113 color=#0000ff size=2><FONT color=#0000ff size=2>string</FONT></FONT><FONT   
    114 size=2> viewMode, </FONT><FONT color=#2b91af size=2><FONT color=#2b91af   
    115 size=2>List</FONT></FONT><FONT   
    116 size=2>&lt;Telerik.Cms.Web.UI.Backend.</FONT><FONT color=#2b91af size=2><FONT   
    117 color=#2b91af size=2>CommandItem</FONT></FONT><FONT size=2>&gt; commandsInfo,   
    118 </FONT><FONT color=#2b91af size=2><FONT color=#2b91af   
    119 size=2>List</FONT></FONT><FONT size=2>&lt;Telerik.Web.</FONT><FONT color=#2b91af   
    120 size=2><FONT color=#2b91af size=2>ICommandPanel</FONT></FONT><FONT size=2>&gt;   
    121 list) </P> 
    122 <P></P> 
    123 <P></FONT><FONT color=#008000 size=2><FONT color=#008000   
    124 size=2>//base.CreateStandardCommandPanels(viewMode, commandsInfo, list);   
    125 </P></FONT></FONT><FONT size=2>  
    126 <P></P> 
    127 <P>}</P></FONT

    Every thing working fine and While runnig the code its asking for server controls,

    controlPanelView,breadcrumb .

    After adding those controls to the Usercontrol , application started working.

    Please give me a clear description of how to add command panel and control planel by using Usercontrol.

    I want to reuse the Blogs Commad panel and control panels so that I can Avoid re inventing the weel. I have slight modifications in the exsting commad panel and Control panel.

    But It messing up some where.

    Thanks
    Venkat.

  10. Venkat
    Venkat avatar
    105 posts
    Registered:
    20 Nov 2008
    01 May 2009
    Link to this post

    Ivan ,

    The command panel I added is showing up in Control panel area.

    Here I am giving you the steps i did

    1)created a MyCommandPanel in App_Code.
    2)created a UserControl with the same name in Blogs folder.
    3)changed the Config file settings as given below

    <

     

    viewSettings hostType="Telerik.Blogs.WebControls.Admin.BlogsControlPanel, Telerik.Blogs" layoutTemplatePath="~/Sitefinity/Admin/ControlTemplates/Blogs/InsightsCommandPanel.ascx" />

     


    And here is the code written in MyCommandPanel.cs 

     

    1 <FONT color=#0000ff size=2><FONT color=#0000ff size=2>  
    2 <P>using</FONT></FONT><FONT size=2> System; </P></FONT><FONT color=#0000ff   
    3 size=2><FONT color=#0000ff size=2>  
    4 <P>using</FONT></FONT><FONT size=2> System.Collections.Generic; </P></FONT><FONT   
    5 color=#0000ff size=2><FONT color=#0000ff size=2>  
    6 <P>using</FONT></FONT><FONT size=2> System.Linq; </P></FONT><FONT color=#0000ff   
    7 size=2><FONT color=#0000ff size=2>  
    8 <P>using</FONT></FONT><FONT size=2> System.Web; </P></FONT><FONT color=#0000ff   
    9 size=2><FONT color=#0000ff size=2>  
    10 <P>using</FONT></FONT><FONT size=2> Telerik.Events.WebControls.Admin;   
    11 </P></FONT><FONT color=#808080 size=2><FONT color=#808080 size=2>  
    12 <P>///</FONT></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>   
    13 </FONT></FONT><FONT color=#808080 size=2><FONT color=#808080   
    14 size=2>&lt;summary&gt;</P> 
    15 <P>///</FONT></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>   
    16 Summary description for MyCommandPanel</P></FONT></FONT><FONT   
    17 color=#808080 size=2><FONT color=#808080 size=2>  
    18 <P>///</FONT></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>   
    19 </FONT></FONT><FONT color=#808080 size=2><FONT color=#808080   
    20 size=2>&lt;/summary&gt;</P></FONT></FONT><FONT color=#0000ff size=2><FONT   
    21 color=#0000ff size=2>  
    22 <P>public</FONT></FONT><FONT size=2</FONT><FONT color=#0000ff size=2><FONT   
    23 color=#0000ff size=2>class</FONT></FONT><FONT size=2</FONT><FONT color=#2b91af   
    24 size=2><FONT color=#2b91af size=2>MyCommandPanel</FONT></FONT><FONT   
    25 size=2>: Telerik.Blogs.WebControls.Admin.</FONT><FONT color=#2b91af size=2><FONT   
    26 color=#2b91af size=2>BlogsControlPanel</FONT></FONT><FONT size=2</P> 
    27 <P>{</P> 
    28 <P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    29 size=2>public</FONT></FONT><FONT size=2> InsightsCommandPanel() : </FONT><FONT   
    30 color=#0000ff size=2><FONT color=#0000ff size=2>base</FONT></FONT><FONT   
    31 size=2>(</FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    32 size=2>false</FONT></FONT><FONT size=2>) </P> 
    33 <P></P> 
    34 <P></P> 
    35 <P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    36 size=2>protected</FONT></FONT><FONT size=2</FONT><FONT color=#0000ff   
    37 size=2><FONT color=#0000ff size=2>override</FONT></FONT><FONT size=2>   
    38 </FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    39 size=2>void</FONT></FONT><FONT size=2>   
    40 CreateCommandPanelsFromUserControls(</FONT><FONT color=#0000ff size=2><FONT   
    41 color=#0000ff size=2>string</FONT></FONT><FONT size=2> viewMode, </FONT><FONT   
    42 color=#2b91af size=2><FONT color=#2b91af size=2>List</FONT></FONT><FONT   
    43 size=2>&lt;</FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    44 size=2>string</FONT></FONT><FONT size=2>&gt; userControls, </FONT><FONT   
    45 color=#2b91af size=2><FONT color=#2b91af size=2>List</FONT></FONT><FONT   
    46 size=2>&lt;Telerik.Web.</FONT><FONT color=#2b91af size=2><FONT color=#2b91af   
    47 size=2>ICommandPanel</FONT></FONT><FONT size=2>&gt; list) </P> 
    48 <P></P> 
    49 <P></FONT><FONT color=#008000 size=2><FONT color=#008000   
    50 size=2>//base.CreateCommandPanelsFromUserControls(viewMode, userControls, list);   
    51 </P></FONT></FONT><FONT size=2>  
    52 <P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    53 size=2>if</FONT></FONT><FONT size=2> (userControls == </FONT><FONT color=#0000ff   
    54 size=2><FONT color=#0000ff size=2>null</FONT></FONT><FONT size=2>) </P> 
    55 <P>userControls = </FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    56 size=2>new</FONT></FONT><FONT size=2</FONT><FONT color=#2b91af size=2><FONT   
    57 color=#2b91af size=2>List</FONT></FONT><FONT size=2>&lt;</FONT><FONT   
    58 color=#0000ff size=2><FONT color=#0000ff size=2>string</FONT></FONT><FONT   
    59 size=2>&gt;(); </P> 
    60 <P></P>  
    61 <P>userControls.Add(</FONT><FONT color=#a31515 size=2><FONT color=#a31515   
    62 size=2>"~/Sitefinity/Admin/ControlTemplates/Blogs/InsightsCommandPanel.ascx"</FONT></FONT><FONT   
    63 size=2>); </P> 
    64 <P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    65 size=2>base</FONT></FONT><FONT   
    66 size=2>.CreateCommandPanelsFromUserControls(viewMode, userControls, list); </P> 
    67 <P>}</P> 
    68 <P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>//public   
    69 override string CreateRootViewCommand(string param, string parentId, params   
    70 Type[] viewsChain)</P></FONT></FONT><FONT size=2>  
    71 <P></FONT><FONT color=#008000 size=2><FONT color=#008000   
    72 size=2>//{</P></FONT></FONT><FONT size=2>  
    73 <P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>// return   
    74 base.CreateRootViewCommand(param, parentId, viewsChain);</P></FONT></FONT><FONT   
    75 size=2>  
    76 <P></FONT><FONT color=#008000 size=2><FONT color=#008000   
    77 size=2>//}</P></FONT></FONT><FONT size=2>  
    78 <P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>//protected   
    79 override void InitializeControls(System.Web.UI.Control   
    80 container)</P></FONT></FONT><FONT size=2>  
    81 <P></FONT><FONT color=#008000 size=2><FONT color=#008000   
    82 size=2>//{</P></FONT></FONT><FONT size=2>  
    83 <P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>//   
    84 base.InitializeControls(container);</P></FONT></FONT><FONT size=2>  
    85 <P></FONT><FONT color=#008000 size=2><FONT color=#008000   
    86 size=2>//}</P></FONT></FONT><FONT size=2>  
    87 <P></P>  
    88 <P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>// second way   
    89 </P></FONT></FONT><FONT size=2>  
    90 <P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    91 size=2>protected</FONT></FONT><FONT size=2</FONT><FONT color=#0000ff   
    92 size=2><FONT color=#0000ff size=2>override</FONT></FONT><FONT size=2>   
    93 </FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    94 size=2>void</FONT></FONT><FONT size=2> CreateCustomCommandPanels(</FONT><FONT   
    95 color=#0000ff size=2><FONT color=#0000ff size=2>string</FONT></FONT><FONT   
    96 size=2> viewMode, </FONT><FONT color=#2b91af size=2><FONT color=#2b91af   
    97 size=2>List</FONT></FONT><FONT size=2>&lt;Telerik.Web.</FONT><FONT color=#2b91af   
    98 size=2><FONT color=#2b91af size=2>ICommandPanel</FONT></FONT><FONT size=2>&gt;   
    99 list) </P> 
    100 <P></P> 
    101 <P></FONT><FONT color=#008000 size=2><FONT color=#008000   
    102 size=2>//base.CreateCustomCommandPanels(viewMode, list); </P></FONT></FONT><FONT   
    103 size=2>  
    104 <P></P> 
    105 <P></P>  
    106 <P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>//third way   
    107 </P></FONT></FONT><FONT size=2>  
    108 <P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    109 size=2>protected</FONT></FONT><FONT size=2</FONT><FONT color=#0000ff   
    110 size=2><FONT color=#0000ff size=2>override</FONT></FONT><FONT size=2>   
    111 </FONT><FONT color=#0000ff size=2><FONT color=#0000ff   
    112 size=2>void</FONT></FONT><FONT size=2> CreateStandardCommandPanels(</FONT><FONT   
    113 color=#0000ff size=2><FONT color=#0000ff size=2>string</FONT></FONT><FONT   
    114 size=2> viewMode, </FONT><FONT color=#2b91af size=2><FONT color=#2b91af   
    115 size=2>List</FONT></FONT><FONT   
    116 size=2>&lt;Telerik.Cms.Web.UI.Backend.</FONT><FONT color=#2b91af size=2><FONT   
    117 color=#2b91af size=2>CommandItem</FONT></FONT><FONT size=2>&gt; commandsInfo,   
    118 </FONT><FONT color=#2b91af size=2><FONT color=#2b91af   
    119 size=2>List</FONT></FONT><FONT size=2>&lt;Telerik.Web.</FONT><FONT color=#2b91af   
    120 size=2><FONT color=#2b91af size=2>ICommandPanel</FONT></FONT><FONT size=2>&gt;   
    121 list) </P> 
    122 <P></P> 
    123 <P></FONT><FONT color=#008000 size=2><FONT color=#008000   
    124 size=2>//base.CreateStandardCommandPanels(viewMode, commandsInfo, list);   
    125 </P></FONT></FONT><FONT size=2>  
    126 <P></P> 
    127 <P>}</P></FONT

    Every thing working fine and While runnig the code its asking for server controls,

    controlPanelView,breadcrumb .

    After adding those controls to the Usercontrol , application started working.

    Please give me a clear description of how to add command panel and control planel by using Usercontrol.

    I want to reuse the Blogs Commad panel and control panels so that I can Avoid re inventing the weel. I have slight modifications in the exsting commad panel and Control panel.

    But It messing up some where.

    Thanks
    Venkat.

  11. Venkat
    Venkat avatar
    105 posts
    Registered:
    20 Nov 2008
    01 May 2009
    Link to this post
    Ivan, sorry,formating of my previous post was not good.

    here is the code.

    using System; 

    using System.Collections.Generic; 

    using System.Linq; 

    using System.Web; 

    using Telerik.Events.WebControls.Admin; 

     

    /// <summary>

    /// Summary description for InsightsCommandPanel

    /// </summary>

    public class MyCommandPanel: Telerik.Blogs.WebControls.Admin.BlogsControlPanel 

    {

          public MyCommandPanel() : base(false) 

        { 

        } 

     

        protected override void CreateCommandPanelsFromUserControls(string viewMode, List<string> userControls, List<Telerik.Web.ICommandPanel> list) 

        { 

            //base.CreateCommandPanelsFromUserControls(viewMode, userControls, list); 

            if (userControls == null) 

                userControls = new List<string>(); 

     

            userControls.Add("~/Sitefinity/Admin/ControlTemplates/Blogs/MyCommandPanel.ascx"); 

            base.CreateCommandPanelsFromUserControls(viewMode, userControls, list); 

        }

     

     

        // second way 

        protected override void CreateCustomCommandPanels(string viewMode, List<Telerik.Web.ICommandPanel> list) 

        { 

            //base.CreateCustomCommandPanels(viewMode, list); 

        } 

     

        //third way 

        protected override void CreateStandardCommandPanels(string viewMode, List<Telerik.Cms.Web.UI.Backend.CommandItem> commandsInfo, List<Telerik.Web.ICommandPanel> list) 

        { 

            //base.CreateStandardCommandPanels(viewMode, commandsInfo, list); 

        } 

     

    }

  12. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    03 May 2009
    Link to this post
    Hello Venkat,

    Please give me a clear description of how to add command panel and control planel by using Usercontrol.

    Please read the post form the links where we have described how to work with new architecture and backend.
    Command Panel: Creating command panel from User Control . The topin covers implementation I sent you im my previuos posts.
    You can add additional views to the base one by creating your view that inhertis ViewModeControl<Host> and inject the view in desired module.

    Let us know if there is anything else that we can do for you.

    Regards,
    Ivan Dimitrov
    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.
  13. Venkat
    Venkat avatar
    105 posts
    Registered:
    20 Nov 2008
    04 May 2009
    Link to this post

    Hi Ivan,

    Still I get no result for my problem.I did what you said in your posts.

    created my own custom controlpanel calss.

    overwitten the CreateView method.

    but there is no ...result at all..the default command panel still showing.

    I set the constructor parameter to false.

    Problem description:

    We are customizing the Blogs module.

    We want to show different commands on the list of posts page

    currently it contain posts,tags,comments,categories.

    I want to hide those and want to show my command panel which contains two or more commands. each command should show different content on the control panel.

    I know there are four methods to implement it.I want to use existing Command panels and overwrite the commands.

    Can you please suggest me which is better.

    please give step by step process.I have read all of your posts.But I think I am missing some thing.

    mailny the config changes that i have to made.

    Thanks Venkat.
  14. Venkat
    Venkat avatar
    105 posts
    Registered:
    20 Nov 2008
    04 May 2009
    Link to this post

    Hi Ivan,

    The steps Waht I did are..!

    Created A Class for InsightsControlPanel.

    Here is the code.

    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Web;
    using Telerik.Cms.Web.UI.Backend;
    using Telerik.Blogs.WebControls.Admin;
    using Telerik.Events.WebControls.Admin;

    /// <summary>
    /// Summary description for InsightsControlPanel
    /// </summary>
    public class InsightsControlPanel : ControlPanel<InsightsControlPanel>
    {
        public InsightsControlPanel()
            : base(false)
        {
            //
            // TODO: Add constructor logic here
            //
        }
        /// <summary>
        /// We add the views to the control panel. The two views we are adding are so called "container" views, since
        /// they do not have user interface and display their default child view.
        /// </summary>
        protected override void CreateViews()
        {
            AddView<BlogsView>("Blogs", "Blogs", "From here you can manage all the blogs.", "all", null);
            AddView<TagsView>("Servises", "Servises", "From here you can manage all the servises", "all", null);
        }
    }

    and here is the Config file changes that i made.

            <viewSettings hostType="Telerik.Blogs.WebControls.Admin.BlogsControlPanel, Telerik.Blogs"  >
                <views>
                    <remove name="BlogsControlPanel"></remove>
                    <add name="InsightsControlPanel" viewType="InsightsControlPanel, App_Code"></add>
                </views>
            </viewSettings>

    But there is no change at all.

    My requirement is.

    I m dividing the tags into three types

    industries,services,documents. by adding a prefix to each tag while saving into the db.

    then while showing the Tags I want to show them as

    Industries,services and documents on the command panel.

    the control panel should display the tags that match the corresponding Tag Prefix.

    And The user can edit and delete the Tag here.

    This I done in the 3.5 by using the user controls and by hiding the un necessary controls .

    but 3.6 is some what different that's why I got confused .

    please give me a clear solution my problem.

    Thanks in advance.
    Venkat.


     

  15. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    05 May 2009
    Link to this post
    Hello Venkat,

    The code does not seems to be correct:

    1. You are inheriting the ControlPanel you have just created

    public class InsightsControlPanel : ControlPanel<InsightsControlPanel>  

    2. You are trying to map the control panel through ControlsConfig file which probably will not do the trick. I suggest that you should create a class that inherits BlogModule and override CreateControlPanel property where you should return your control panel.

    Kind regards,
    Ivan Dimitrov
    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.
  16. Venkat
    Venkat avatar
    105 posts
    Registered:
    20 Nov 2008
    17 Jun 2009
    Link to this post

    The zip file Sitefinity_3_6_1920_standard_ExternalTemplates.zip

    Does not contain the control templates for News letters .I want to customize the news letters according to our site specifications.

    How can get those Control templates related to NewsLetters.

    Can any one please help me

    Thanks
    Venkat
  17. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    17 Jun 2009
    Link to this post
    Hi Venkat,

    Notifications templates are not migrated and they are located under Sitefinity/Admin/ControlTemplates/Notifications

    Best wishes,
    Ivan Dimitrov
    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.
Register for webinar
17 posts, 0 answered