Passing Data between two usercontrols in asp.net
<p>i have a UC_Categories.ascx  <strong>( UC_1 )</strong> which constraints categoryname . UC_Products.ascx <strong>( UC_2 )</strong> will show products by categoryname. Both of them are in a <strong>Page</strong> called BookShop.aspx ( Page )</p>

<p>In the Page, when user click a <strong>UC_1</strong> (step 1 ) , it will render a <strong>UC_2</strong> by categoryname (step2 ). I process step 1 by sending a request with param that is categoryname to <strong>Page</strong>. Step2  create a new <strong>UC_2</strong> ,set Properties value that is categoryname , and execute FillProductByCategoryName method. then add <strong>UC_2</strong> to a PlaceHolder in the Page. but i don't show <strong>UC_2</strong> . </p>

<p>I need a help or suggest from everyone.</p>

<p>Thank you for reading my question!
ps : my english isn't very well.</p>

<p>in the codebehind of the UC2 :</p>

<pre><code>public void FillProduct()
    {

        ProductsMN productsMN = new ProductsMN();
        if (dlBook == null)
        {
            dlBook = new DataList();
            dlBook.DataSource = productsMN.GetByCategoryName(CategoryName);
            dlBook.DataBind();
        }
        else
        {
            dlBook.DataSource = productsMN.GetByCategoryName(CategoryName);
            dlBook.DataBind();
        }
    }

    public string CategoryName { get; set; }
</code></pre>

<p>in the codebehind of the page </p>

<pre><code> protected void Page_Load(object sender, EventArgs e)
    {

        if (!IsPostBack)
        {
        }
        string categoryName = Request.QueryString["categoryName"] as string;
        if (!string.IsNullOrWhiteSpace(categoryName))
        {
            BookContent.Controls.Clear(); // BookContent : Placeholder
            Control c = Page.LoadControl("~/UC/UC_Books.ascx") as UC.UC_Books;
            UC.UC_Books ucBook = new UC.UC_Books();
            ucBook.CategoryName = categoryName;
            ucBook.FillProduct(); //line 10
            BookContent.Controls.Add(ucBook); //line 11
        }

    }
</code></pre>

<p>at the PageLoad of the Page, useBook contains data. but in the Page (view ), i don't see data. i think //line11 isn't execute or not true .</p>
