title: values does not show in my Modal
body: <p>The values of the textboxs does not come up. whats wrong with my code? the modal shows up but it does not get the values of the table. I made a rowcommand of it and put the code in there. but no show. can someone help me please.</p>
  
  <p>Thank you!</p>
  
  <p>This is my .cs code</p>
  
  <pre><code>protected void GridView1_RowCommand(object sender, GridViewCommandEventArgs e)
      {
          int i = Convert.ToInt32(e.CommandArgument);
  
  
  
          GridViewRow gvrow = GridView1.Rows[i];
          txtID.Text = gvrow.Cells[0].Text;
          txtType.Text = gvrow.Cells[1].Text;
          txtModel.Text = gvrow.Cells[2].Text;
          txtQuan.Text = HttpUtility.HtmlDecode(gvrow.Cells[3].Text);
          txtUnit.Text = HttpUtility.HtmlDecode(gvrow.Cells[4].Text);
          txtDate.Text = HttpUtility.HtmlDecode(gvrow.Cells[5].Text);
          txtDesc.Text = HttpUtility.HtmlDecode(gvrow.Cells[6].Text);
  
  
          //txtID.Text = GridView1.Rows[i].Cells[0].Text.ToString();
  
  
              lblResult.Visible = false;
  
              System.Text.StringBuilder sb = new System.Text.StringBuilder();
              sb.Append(@"&lt;script type='text/javascript'&gt;");
              sb.Append("$('#editModal').modal('show');");
              sb.Append(@"&lt;/script&gt;");
              ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "EditModalScript", sb.ToString(), false);
  
  
      }
  </code></pre>
  
  <p>Here is my modal div code</p>
  
  <pre><code>&lt;div id="editModal" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="editModalLabel" aria-hidden="true"&gt;
      &lt;div class="modal-dialog"&gt;
          &lt;div class="modal-content"&gt;
              &lt;div class="modal-header"&gt;
                  &lt;button type="button" class="close" data-dismiss="modal" aria-hidden="true"&gt;x&lt;/button&gt;
                  &lt;h3 id="editModalLabel"&gt;View Details&lt;/h3&gt;
              &lt;/div&gt;    
  &lt;asp:UpdatePanel ID="upEdit" runat="server"&gt;
      &lt;ContentTemplate&gt;
          &lt;div class ="modal-body"&gt;
              &lt;table class="table"&gt;
                  &lt;tr&gt;
                      &lt;td&gt;Item ID:
                          &lt;asp:TextBox ID="txtID" runat="server"&gt;&lt;/asp:TextBox&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr&gt;
                      &lt;td&gt;Type:
                          &lt;asp:TextBox ID="txtType" runat="server"&gt;&lt;/asp:TextBox&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr&gt;
                      &lt;td&gt;Model:
                          &lt;asp:TextBox ID="txtModel" runat="server"&gt;&lt;/asp:TextBox&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr&gt;
                      &lt;td&gt;Requested Quantity:
                          &lt;asp:TextBox ID="txtQuan" runat="server"&gt;&lt;/asp:TextBox&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr&gt;
                      &lt;td&gt;Unit:
                          &lt;asp:TextBox ID="txtUnit" runat="server"&gt;&lt;/asp:TextBox&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr&gt;
                      &lt;td&gt;Date Needed:
                          &lt;asp:TextBox ID="txtDate" runat="server"&gt;&lt;/asp:TextBox&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr&gt;
                      &lt;td&gt;Description:
                          &lt;asp:TextBox ID="txtDesc" runat="server"&gt;&lt;/asp:TextBox&gt;
                      &lt;/td&gt;
                  &lt;/tr&gt;
              &lt;/table&gt;
          &lt;/div&gt;
          &lt;div class="modal-footer"&gt;
              &lt;asp:Label ID="lblResult" Visible="false" runat="server"&gt;&lt;/asp:Label&gt;
              &lt;asp:Button ID ="btnSave" runat="server" Text="Approve" CssClass="btn btn-primary" OnClick="btnSave_Click" /&gt;
              &lt;button class="btn btn-info" data-dismiss="modal" aria-hidden="true"&gt;Close&lt;/button&gt;
          &lt;/div&gt;
      &lt;/ContentTemplate&gt;
      &lt;Triggers&gt;
          &lt;asp:AsyncPostBackTrigger ControlID="GridView1" EventName="RowCommand" /&gt;
          &lt;asp:AsyncPostBackTrigger ControlID ="btnSave" EventName="Click" /&gt;
      &lt;/Triggers&gt;
  &lt;/asp:UpdatePanel&gt;
      &lt;/div&gt;
          &lt;/div&gt;
      &lt;/div&gt;
  </code></pre>
  
  <p>MARKUP OF My GRIDVIEW 1</p>
  
  <pre><code>&lt;asp:UpdatePanel ID="panel1" runat="server"&gt;
       &lt;ContentTemplate&gt;
  &lt;asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="false" DataKeyNames="TransactionID" OnRowDataBound="GridView1_OnRowDataBound" OnRowCommand="GridView1_RowCommand" CellPadding="4" AllowPaging="true" PageIndex="2" OnPageIndexChanging="GridView1_PageIndexChanging" HeaderStyle-BackColor ="CornflowerBlue" BorderWidth="1" BorderColor="Gray" Width="100%" CssClass=" table table-hover" &gt;
      &lt;Columns&gt;
          &lt;asp:TemplateField&gt;
              &lt;ItemTemplate&gt;
                  &lt;asp:CheckBox ID="chkSelect" runat="server"  /&gt;
              &lt;/ItemTemplate&gt;
          &lt;/asp:TemplateField&gt;
          &lt;asp:TemplateField&gt;
              &lt;ItemTemplate&gt;
                  &lt;img style="cursor:pointer" src ="../Images/Icons/plus2.png" /&gt;
                  &lt;asp:Panel ID ="pnlDetails" runat="server" Style="display: none"&gt;
                      &lt;asp:GridView ID="gvDet" runat="server" AutoGenerateColumns="false" CssClass="ChildGrid"&gt;
                          &lt;Columns&gt;
                              &lt;%--&lt;asp:BoundField ItemStyle-Width="20px" DataField="ID" HeaderText="ID" /&gt;--%&gt;
                              &lt;asp:BoundField ItemStyle-Width="200px" DataField="ItemType" HeaderText="Type" /&gt;
                              &lt;asp:BoundField ItemStyle-Width="250px" DataField="ItemModel" HeaderText="Model" /&gt;
                              &lt;asp:BoundField ItemStyle-Width="140px" DataField="ItemQuantity" HeaderText="Requested Quantity" /&gt;
                              &lt;asp:BoundField ItemStyle-Width="80px" DataField="ItemUnit" HeaderText="Unit" /&gt;
                              &lt;asp:BoundField ItemStyle-Width="100px" DataField="ItemDate" HeaderText="Date Needed" /&gt;
                              &lt;asp:BoundField ItemStyle-Width="200px" DataField="ItemDesc" HeaderText="Description" /&gt;
                              &lt;%--&lt;asp:BoundField ItemStyle-Width="80px" DataField="ItemStatus" HeaderText="Status" /&gt;--%&gt;
                          &lt;/Columns&gt;
                      &lt;/asp:GridView&gt;
                  &lt;/asp:Panel&gt;
              &lt;/ItemTemplate&gt;
          &lt;/asp:TemplateField&gt;
          &lt;asp:TemplateField HeaderText="Transaction Number" HeaderStyle-ForeColor="White"&gt;
              &lt;ItemTemplate&gt;
                  &lt;asp:Label ID ="lblmosID" runat="server" Text='&lt;%#Bind ("TransactionID") %&gt;'&gt;&lt;/asp:Label&gt;
              &lt;/ItemTemplate&gt;
              &lt;ItemStyle Width="30px" Font-Size="15px" Font-Names="Calibri" /&gt;
          &lt;/asp:TemplateField&gt;
          &lt;asp:TemplateField HeaderText="Date" HeaderStyle-ForeColor="White"&gt;
              &lt;ItemTemplate&gt;
                  &lt;asp:Label ID ="lblDate" runat="server" Text='&lt;%#Bind ("DateFiled") %&gt;'&gt;&lt;/asp:Label&gt;
              &lt;/ItemTemplate&gt;
              &lt;ItemStyle Width="130px" Font-Names="Calibri" /&gt;
          &lt;/asp:TemplateField&gt;
          &lt;asp:TemplateField HeaderText="Name" HeaderStyle-ForeColor="White"&gt;
              &lt;ItemTemplate&gt;
                  &lt;asp:Label ID ="lblName" runat="server" Text='&lt;%#Bind ("ReqName") %&gt;'&gt;&lt;/asp:Label&gt;
              &lt;/ItemTemplate&gt;
              &lt;ItemStyle Font-Names="Calibri" /&gt;
          &lt;/asp:TemplateField&gt;
          &lt;asp:TemplateField HeaderText="Company" HeaderStyle-ForeColor="White"&gt;
              &lt;ItemTemplate&gt;
                  &lt;asp:Label ID ="lblComp" runat="server" Text='&lt;%#Bind ("ReqCompany") %&gt;'&gt;&lt;/asp:Label&gt;
              &lt;/ItemTemplate&gt;
              &lt;ItemStyle Font-Names="Calibri" /&gt;
          &lt;/asp:TemplateField&gt;
          &lt;asp:TemplateField HeaderText="Branch" HeaderStyle-ForeColor="White"&gt;
              &lt;ItemTemplate&gt;
                  &lt;asp:Label ID ="lblBranch" runat="server" Text='&lt;%#Bind ("ReqBranch") %&gt;'&gt;&lt;/asp:Label&gt;
              &lt;/ItemTemplate&gt;
              &lt;ItemStyle Font-Names ="Calibri" /&gt;
          &lt;/asp:TemplateField&gt;
          &lt;asp:TemplateField HeaderText="Business Unit" HeaderStyle-ForeColor="White"&gt;
              &lt;ItemTemplate&gt;
                  &lt;asp:Label ID ="lblBU" runat="server" Text='&lt;%#Bind ("ReqBU") %&gt;'&gt;&lt;/asp:Label&gt;
              &lt;/ItemTemplate&gt;
              &lt;ItemStyle Font-Names="Calibri" /&gt;
          &lt;/asp:TemplateField&gt;
          &lt;asp:TemplateField HeaderText="Department" HeaderStyle-ForeColor="White"&gt;
              &lt;ItemTemplate&gt;
                  &lt;asp:Label ID ="lblDept" runat="server" Text='&lt;%#Bind ("ReqDept") %&gt;'&gt;&lt;/asp:Label&gt;
              &lt;/ItemTemplate&gt;
              &lt;ItemStyle Font-Names="Calibri" /&gt;
          &lt;/asp:TemplateField&gt;
          &lt;asp:TemplateField HeaderText="Section" HeaderStyle-ForeColor="White"&gt;
              &lt;ItemTemplate&gt;
                  &lt;asp:Label ID ="lblsection" runat="server" Text='&lt;%#Bind ("ReqSection") %&gt;'&gt;&lt;/asp:Label&gt;
              &lt;/ItemTemplate&gt;
              &lt;ItemStyle Font-Names="Calibri" /&gt;
          &lt;/asp:TemplateField&gt;
          &lt;asp:TemplateField HeaderText="Status" HeaderStyle-ForeColor="White"&gt;
              &lt;ItemTemplate&gt;
                  &lt;asp:Label ID ="lblStatus" runat="server" Text='&lt;%#Bind ("TransStatus") %&gt;'&gt;&lt;/asp:Label&gt;
              &lt;/ItemTemplate&gt;
              &lt;ItemStyle Font-Names="Calibri" /&gt;
          &lt;/asp:TemplateField&gt;
          &lt;%--&lt;asp:TemplateField HeaderText=""&gt;
              &lt;ItemTemplate&gt;
                  &lt;asp:LinkButton ID ="lnkEdit" runat="server" Text="View" PostBackUrl='&lt;%# "Details.aspx?Id=" + Eval("TransactionID") %&gt;'&gt;&lt;/asp:LinkButton&gt;
              &lt;/ItemTemplate&gt;
          &lt;/asp:TemplateField&gt;--%&gt;
          &lt;asp:ButtonField CommandName="editRecord" ControlStyle-CssClass="btn btn-info" ButtonType="Button" Text="View" HeaderText="View Request" HeaderStyle-ForeColor="White"&gt;
          &lt;ControlStyle CssClass ="btn btn-info" /&gt;    
          &lt;/asp:ButtonField&gt;
      &lt;/Columns&gt;
      &lt;HeaderStyle BackColor="CornflowerBlue" /&gt;
  &lt;/asp:GridView&gt;
           &lt;/ContentTemplate&gt;
       &lt;Triggers&gt;
           &lt;asp:AsyncPostBackTrigger ControlID="GridView1" /&gt;
       &lt;/Triggers&gt;
       &lt;/asp:UpdatePanel&gt;
  </code></pre>
  
  <p>Whats wrong with my code? </p>
  
  <p>Thanks!</p>