[CLOSED] Passing Parameter To Ascx Via Loader

  1. #1

    [CLOSED] Passing Parameter To Ascx Via Loader

    Hi,

    I am trying to create items dynamically in ascx like this example. But i have to pass parameters from parent page to DynamicItems.ascx.

    Can you advice a way to do this?

    Regards,

    Vzx
    Last edited by Daniil; May 17, 2013 at 10:03 AM. Reason: [CLOSED]
  2. #2
    You can load user control manually, set required properties for user control and render it
    MyUserControl uc = (MyUserControl)UserControlRenderer.LoadControl(path);
    uc.Property1 = "value1";
    
    return ComponentLoader.ToConfig(uc);
  3. #3
    Quote Originally Posted by Vladimir View Post
    You can load user control manually, set required properties for user control and render it
    MyUserControl uc = (MyUserControl)UserControlRenderer.LoadControl(path);
    uc.Property1 = "value1";
    
    return ComponentLoader.ToConfig(uc);
    Thank you Vladimir.

Similar Threads

  1. [CLOSED] How to passing DateFields from ascx to aspx file
    By Zenalyse in forum 2.x Legacy Premium Help
    Replies: 1
    Last Post: Mar 04, 2013, 2:12 PM
  2. How to passing parameter in TreeNode
    By teamsar in forum 2.x Help
    Replies: 0
    Last Post: Jan 29, 2013, 10:06 AM
  3. [CLOSED] Getting the parameter defined in ext:Window Loader
    By supera in forum 2.x Legacy Premium Help
    Replies: 5
    Last Post: Feb 17, 2012, 1:27 PM
  4. Replies: 0
    Last Post: Jan 26, 2011, 8:38 AM
  5. Passing parameter to Ajax Method
    By shijith in forum 1.x Help
    Replies: 1
    Last Post: Jul 26, 2010, 12:52 PM

Tags for this Thread

Posting Permissions