1-888-365-2779
+1-888-365-2779
Try Now
More in this section

Forums / Developing with Sitefinity / Module Development

Module Development

3 posts, 1 answered
  1. David
    David  avatar
    78 posts
    Registered:
    29 Dec 2008
    13 Oct 2009
    Link to this post
    I am looking at adding another view to the backend under override void CreateViews. 

    Example
     AddView("OfficeListView", "~/custom/backend/Offices/OfficeList.ascx", "View Office List", "View Office List", "all", null);  
     AddView("OfficeEditView", "~/custom/backend/Offices/OfficeEdit.ascx", "Add an Office", "Add an Office", "all", null);  
            

    This will list Add an Office on the hand side.  If I want to link to view I can just make a call to OfficeEditView.
    CreateHostViewCommand("OfficeEditView", office.OfficeId.ToString(), null);  

    What if I don't want to show Add an Office on the left, but I still want the call to the view via CreateHostViewCommand  to be available?

    I tried searching in the online developers manual for CreateViews, nothing returns.  Can someone provide me a link in the documentations for those methods.  I am sure I am missing cool items.

    Thanks,
    David

  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    16 Jun 2017
    13 Oct 2009
    Link to this post
    Hello David ,

    Generally the CreateHostViewCommands are assigned to NavigateUrl property of a link. You could try using ResponseRedirect or  permission check. Another option is using String.Empty for the Title and Description of AddView.

    Best wishes,
    Ivan Dimitrov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
    Answered
  3. David
    David  avatar
    78 posts
    Registered:
    29 Dec 2008
    13 Oct 2009
    Link to this post
    Hi Ivan,
      Yea I assigned the  assign CreateHostViewCommands to a NavigateURL within a RadGrid.   The used the second option string.empty and it work great.  The views are all linking up nicely now, just have to connect the data to the form now.  Thanks, almost done.

    Thanks,
    David
Register for webinar
3 posts, 1 answered