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

Forums / Developing with Sitefinity / Get value between two controls on a page

Get value between two controls on a page

3 posts, 0 answered
  1. Siddesh Kapadi
    Siddesh Kapadi avatar
    239 posts
    Registered:
    09 Oct 2009
    12 Aug 2010
    Link to this post
    Hey,
    I have two controls dragged on a page, for example a.ascx and b.ascx. 
    a.ascx consists of a literal control with some value set by the user.
    I need to pass the value to b.ascx and display few content there as per the selection.

    How can this be acheived?

    Thanks & Regards,
    Siddesh Kapadi
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    09 Dec 2016
    12 Aug 2010
    Link to this post
    Hi Siddesh Kapadi,

    You can use QueryString or Session to pass some values between the controls. Another option is accessing the properties of control a - you can get the control from page.controls collection, cast the control to ICmsWebControl, read its property and decide what to show with control b.

    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
  3. Siddesh Kapadi
    Siddesh Kapadi avatar
    239 posts
    Registered:
    09 Oct 2009
    12 Aug 2010
    Link to this post
    Hey,
    From the below example, b.ascx is available on the master template and a.ascx is available on the page. I need to pass the value from page control to the Master Page Control. Please let me know how can I achieve this.

    Regards,
    Siddesh Kapadi
Register for webinar
3 posts, 0 answered