Dynamically binding headers reference in aspx page.
Example:
I have used multiple headers reference in single page in c#. Is there any way to bind these headers dynamicaly??
- <%@ Register TagPrefix="uc" TagName="SearchCountryObControl" Src="~/APIControls/SearchCountryObControl.ascx" %>
- <%@ Register TagPrefix="uc" TagName="GetCompanyInfoControl" Src="~/APIControls/GetCompanyInfoControl.ascx" %>
- <%@ Register TagPrefix="uc" TagName="SearchCityObControl" Src="~/APIControls/SearchCityObControl.ascx" %>
- <%@ Register TagPrefix="uc" TagName="GetUserRoutingProfilesControl" Src="~/APIControls/GetUserRoutingProfilesControl.ascx" %>
- <%@ Register TagPrefix="uc" TagName="GetRatePlanObControl" Src="~/APIControls/GetRatePlanObControl.ascx" %>
- <%@ Register TagPrefix="uc" TagName="CompanyBilling1EControl" Src="~/APIControls/CompanyBilling1EControl.ascx" %>
- <%@ Register TagPrefix="uc" TagName="GetAllProfilesControl" Src="~/APIControls/GetAllProfilesControl.ascx" %>
below the method are calling like in aspx page(note that there is no code behind):
at single time i used only 1 reference.
- var searchCountry = new Voice.Vpbx.Api.UI.APIControls.SearchCountryObControl.SearchCountryObHelper();
- var xml_response = searchCountry.GetAllCountry(lcData);
- var searchCity = new Voice.Vpbx.Api.UI.APIControls.SearchCityObControl.SearchCityObHelper();
- var xml_response = searchCity.GetAllInternationalCity(lcData);
is there any way to bind these reference dynamically i.e. if this page loads then all the reference are loads so i want to load the single refrence by using dynamically. Is there any best way to do?