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

Forums / Developing with Sitefinity / optimize registering webservices

optimize registering webservices

4 posts, 0 answered
  1. Pierre
    Pierre avatar
    433 posts
    Registered:
    16 Feb 2006
    02 Jun 2010
    Link to this post
    Hi Team,

    I use many webservices in custom modules registred under RadScriptManager or ScriptManagers in Admin master page.I can't see ours webservices registred using services tag. Exist another way to registering these webservices to use in modules client side by code?.

    std way :
    <asp:ScriptManager ID="scriptManger1" runat="server">
    <Services>
    <asp:ServiceReference Path="~/WebService.asmx" />
    </Services>
    </asp:ScriptManager>

    Thanks.


     
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    16 Jun 2017
    02 Jun 2010
    Link to this post
    Hi Pierre,

    The ScriptManager is used when you are creating JavaScript Proxies. You can define the  web Service in the masterpage

    <script src="CustomersService.asmx/js" type="text/javascript"></script>


    Another option is invoking the WebService through JavaScript- useService Method


    Regards,
    Ivan Dimitrov
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
  3. Pierre
    Pierre avatar
    433 posts
    Registered:
    16 Feb 2006
    02 Jun 2010
    Link to this post
    Hi,

    Ok, but what is the method implemented to registering the services used by Telerik.Cms.Engine.Services like ContentService.asmx(sf/service folder). I can't see where are registred to be called later in the Module (no in admin.master, not in Modules page, not in Telerik.News.WebControls.Admin.controls...).
    Other method is used in base ?

    Thanks.  
  4. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    16 Jun 2017
    02 Jun 2010
    Link to this post
    Hello Pierre,

    We use instance of ServiceReference inside OnPreRender event of the backend views

    ContentItemsList

    ServiceReference reference = new ServiceReference("~/Sitefinity/Admin/Services/ContentService.asmx");

    you can use the following format as well

    %@ WebService Language="C#" Class="Sample.Module.Services.ModuleService, Sample.Module" %>


    Sincerely yours,
    Ivan Dimitrov
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
Register for webinar
4 posts, 0 answered