title: Group Repeater for each Distinct User
body: <p>I have the following repeater item:</p>
  
  <pre><code>&lt;asp:Repeater ID="RptLeaveRequests" runat="server" 
          onitemdatabound="RptLeaveRequests_ItemDataBound"&gt;
  &lt;ItemTemplate&gt;
      &lt;table id="tableItem" runat="server"&gt;
          &lt;tr&gt;
                  &lt;td style="width: 100px;"&gt;
                      &lt;asp:Label ID="lblDate" runat="server" Text='&lt;%#Eval("Date", "{0:dd/M/yyyy}") %&gt;'&gt;&lt;/asp:Label&gt;
                  &lt;/td&gt;
                  &lt;td style="width: 100px;"&gt;
                      &lt;asp:Label ID="lblHours" runat="server" Text='&lt;%#Eval("Hours") %&gt;'&gt;&lt;/asp:Label&gt;
                  &lt;/td&gt;
                  &lt;td style="width: 200px;"&gt;
                      &lt;asp:Label ID="lblPeriod" runat="server" Text='&lt;%#Eval("AMorPM") %&gt;'&gt;&lt;/asp:Label&gt;
                  &lt;/td&gt;
                  &lt;td style="width: 200px; font-size:10px;"&gt;
                      &lt;asp:Label ID="lblNote" runat="server" Text='&lt;%#Eval("Note") %&gt;'&gt;&lt;/asp:Label&gt;
                  &lt;/td&gt;
                  &lt;td style="50px"&gt;
                      &lt;asp:RadioButtonList ID="rbtVerified" runat="server" &gt;
                          &lt;asp:ListItem Value="1"&gt;Accept&lt;/asp:ListItem&gt;
                          &lt;asp:ListItem Value="2"&gt;Reject&lt;/asp:ListItem&gt;
                      &lt;/asp:RadioButtonList&gt;
                  &lt;/td&gt;
                  &lt;td&gt;
                      &lt;asp:TextBox ID="txtNotes" runat="server" &gt;&lt;/asp:TextBox&gt;
                  &lt;/td&gt;
              &lt;/tr&gt;
      &lt;/table&gt;
  &lt;/ItemTemplate&gt;
  &lt;/asp:Repeater&gt;
  </code></pre>
  
  <p>on page load I am binding the Repeater</p>
  
  <pre><code>else if(Convert.ToInt32(Session["UserLevel"]) != 0 &amp;&amp; Convert.ToInt32(Session["UserLevel"]) &lt; 151)
  {
         RptLeaveRequests.DataSource = newLeaveLogic().GetManagerUnverifiedLeaveRequests(Convert.ToInt32(Context.User.Identity.Name));
          RptLeaveRequests.DataBind();
          hasRequests = true;
  }
  </code></pre>
  
  <p>Now how can group the Repeater item for each distinct user returned by the GetManagerUnferifiedLeaveRequests which returns a DataTable in the method below:</p>
  
  <pre><code>protected void RptLeaveRequests_ItemDataBound(object sender, RepeaterItemEventArgs e)
  {
         if (hasRequests)
         {
               //grouping
         }
  }
  </code></pre>