how to display data in table from database based on selected row from gridview











up vote
0
down vote

favorite












am trying to retrieve data from the database to be shown in a modal box containing a datatable with the details of the selected row. The problem im encountering seems to be that regardless of the rows i chose, the modal box showing the details only uses the first row from the database. heres the asp.net code for the gridview.



Gridview:



<asp:GridView ID="smry" runat="server" AutoGenerateColumns="False" OnRowCommand="GridView1_RowCommand" CssClass="list-group" >
<Columns>
<asp:ButtonField Text="View" CommandName="Viewdet"/>
<asp:TemplateField HeaderText="MRF No">
<ItemTemplate>
<asp:Label ID="mrfnoret" runat="server" Text='<%# Eval("MRF_No") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:BoundField DataField="BU" HeaderText="Business Unit" SortExpression="BU" />
<asp:BoundField DataField="Dept" HeaderText="Department" SortExpression="Dept" />
<asp:BoundField DataField="ReqByDept_Mngr" HeaderText="Reqested By" SortExpression="ReqByDept_Mngr" />
</Columns>
</asp:GridView>


code behind:



protected void GridView1_RowCommand(object sender, GridViewCommandEventArgs e)
{


if(e.CommandName == "Viewdet")
{


database db = new database();
string database = db.MRF();
using (SqlConnection con = new SqlConnection(database))
{
con.Open();

string query = "SELECT [MRF_No], [BU], [Dept], [PostTitle], [ReqdPrsnl], [Rank], [JobFam], [ToEmp], [JobDesc], [Edu], [WorkExp], [ITSkills], [OpMachines], [PersonalAtt], [others], [MinSalRange], [MaxSalRange], [ReqByDept_Mngr], [NoteBy_Bu_Head], [AppByHR_Mngr] FROM MRF_Details"
+ "";
using (SqlCommand com = new SqlCommand(query, con))
using (SqlDataAdapter sda = new SqlDataAdapter(query, con))
{
DataTable dt = new DataTable();
sda.Fill(dt);
details.DataSource = dt;
details.DataBind();
}
con.Close();
}

ScriptManager.RegisterClientScriptBlock(this, this.GetType(),"Pop", "openModal();", true);
}
}


Incase some are wondering i want to retrieve data from the database and show it in a modal box. here is the modal box code as well.



 <div id="TestModal" class="modal fade" role="dialog">
<div class="modal-dialog modal-lg ">
<%-- MODAL CONTENT --%>
<div class="modal-content">
<div class="modal-header">
<asp:Label class="modal-title" runat="server" Text="DETAILS" CssClass="text-pos"></asp:Label>
</div>
<div class="modal-body modalScroll">
<div class ="row next">
<asp:DetailsView runat="server" ID="details" CssClass="table" AutoGenerateRows="false">
<Fields>

<asp:BoundField DataField="MRF_No" HeaderText="MRF No" SortExpression="MRF_No" />
<asp:BoundField DataField="BU" HeaderText="BUSINESS UNIT:" SortExpression="BU" />
<asp:BoundField DataField="Dept" HeaderText="DEPARTMENT:" SortExpression="Dept" />
<asp:BoundField DataField="PostTitle" HeaderText="POSITION TITLE:" SortExpression="PostTitle" />
<asp:BoundField DataField="ReqdPrsnl" HeaderText="NO. OF REQ'D PERSONNEL:" SortExpression="ReqdPrsnl" />
<asp:BoundField DataField="Rank" HeaderText="RANK / LEVEL" SortExpression="Rank" />
<asp:BoundField DataField="JobFam" HeaderText="JOB FAMILY" SortExpression="JobFam" />
<asp:BoundField DataField="ToEmp" HeaderText="TERMS OF EMPLOYMENT" SortExpression="ToEmp" />
<asp:BoundField DataField="JobDesc" HeaderText="DUTIES AND RESPONSIBILITIES" SortExpression="JobDesc" />
<asp:BoundField DataField="Edu" HeaderText="EDUCATION / PRC LICENSES / CERTIFICATIONS" SortExpression="Edu" />
<asp:BoundField DataField="WorkExp" HeaderText="Work Experience" SortExpression="WorkExp" />
<asp:BoundField DataField="ITSkills" HeaderText="IT SKILLS / SOFTWARE & HARDWARE PROFICIENCIES" SortExpression="ITSkills" />
<asp:BoundField DataField="OpMachines" HeaderText="OPERATIONS OF MACHINES" SortExpression="OpMachines" />
<asp:BoundField DataField="PersonalAtt" HeaderText="PERSONAL ATTRIBUTES" SortExpression="PersonalAtt" />
<asp:BoundField DataField="others" HeaderText="OTHERS" SortExpression="others" />
<asp:BoundField DataField="MinSalRange" HeaderText="Minimum Salary Range" SortExpression="MinSalRange" />
<asp:BoundField DataField="MaxSalRange" HeaderText="Maximum Salary Range" SortExpression="MaxSalRange" />
<asp:BoundField DataField="ReqByDept_Mngr" HeaderText="REQUESTED BY:" SortExpression="ReqByDept_Mngr" />
<asp:BoundField DataField="NoteBy_Bu_Head" HeaderText="NOTED BY:" SortExpression="NoteBy_Bu_Head" />
<asp:BoundField DataField="AppByHR_Mngr" HeaderText="APPROVED BY:" SortExpression="AppByHR_Mngr" />

</Fields>
</asp:DetailsView>
</div>
</div>
<div class="modal-footer">
<asp:Button ID="close2" runat="server" Text="Close" data-dismiss="modal" />
</div>
</div>
</div>
</div>









share|improve this question






















  • Your select ... query in C# doesn't depend on a parent row value / key. This is why you receive the same data for all rows. You can send a parameter into GridView1_RowCommand using CommandArgument attribute of the button.
    – Alex Kudryashev
    Nov 18 at 17:33










  • May i know how to apply it here in my code??
    – allos
    Nov 19 at 0:30















up vote
0
down vote

favorite












am trying to retrieve data from the database to be shown in a modal box containing a datatable with the details of the selected row. The problem im encountering seems to be that regardless of the rows i chose, the modal box showing the details only uses the first row from the database. heres the asp.net code for the gridview.



Gridview:



<asp:GridView ID="smry" runat="server" AutoGenerateColumns="False" OnRowCommand="GridView1_RowCommand" CssClass="list-group" >
<Columns>
<asp:ButtonField Text="View" CommandName="Viewdet"/>
<asp:TemplateField HeaderText="MRF No">
<ItemTemplate>
<asp:Label ID="mrfnoret" runat="server" Text='<%# Eval("MRF_No") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:BoundField DataField="BU" HeaderText="Business Unit" SortExpression="BU" />
<asp:BoundField DataField="Dept" HeaderText="Department" SortExpression="Dept" />
<asp:BoundField DataField="ReqByDept_Mngr" HeaderText="Reqested By" SortExpression="ReqByDept_Mngr" />
</Columns>
</asp:GridView>


code behind:



protected void GridView1_RowCommand(object sender, GridViewCommandEventArgs e)
{


if(e.CommandName == "Viewdet")
{


database db = new database();
string database = db.MRF();
using (SqlConnection con = new SqlConnection(database))
{
con.Open();

string query = "SELECT [MRF_No], [BU], [Dept], [PostTitle], [ReqdPrsnl], [Rank], [JobFam], [ToEmp], [JobDesc], [Edu], [WorkExp], [ITSkills], [OpMachines], [PersonalAtt], [others], [MinSalRange], [MaxSalRange], [ReqByDept_Mngr], [NoteBy_Bu_Head], [AppByHR_Mngr] FROM MRF_Details"
+ "";
using (SqlCommand com = new SqlCommand(query, con))
using (SqlDataAdapter sda = new SqlDataAdapter(query, con))
{
DataTable dt = new DataTable();
sda.Fill(dt);
details.DataSource = dt;
details.DataBind();
}
con.Close();
}

ScriptManager.RegisterClientScriptBlock(this, this.GetType(),"Pop", "openModal();", true);
}
}


Incase some are wondering i want to retrieve data from the database and show it in a modal box. here is the modal box code as well.



 <div id="TestModal" class="modal fade" role="dialog">
<div class="modal-dialog modal-lg ">
<%-- MODAL CONTENT --%>
<div class="modal-content">
<div class="modal-header">
<asp:Label class="modal-title" runat="server" Text="DETAILS" CssClass="text-pos"></asp:Label>
</div>
<div class="modal-body modalScroll">
<div class ="row next">
<asp:DetailsView runat="server" ID="details" CssClass="table" AutoGenerateRows="false">
<Fields>

<asp:BoundField DataField="MRF_No" HeaderText="MRF No" SortExpression="MRF_No" />
<asp:BoundField DataField="BU" HeaderText="BUSINESS UNIT:" SortExpression="BU" />
<asp:BoundField DataField="Dept" HeaderText="DEPARTMENT:" SortExpression="Dept" />
<asp:BoundField DataField="PostTitle" HeaderText="POSITION TITLE:" SortExpression="PostTitle" />
<asp:BoundField DataField="ReqdPrsnl" HeaderText="NO. OF REQ'D PERSONNEL:" SortExpression="ReqdPrsnl" />
<asp:BoundField DataField="Rank" HeaderText="RANK / LEVEL" SortExpression="Rank" />
<asp:BoundField DataField="JobFam" HeaderText="JOB FAMILY" SortExpression="JobFam" />
<asp:BoundField DataField="ToEmp" HeaderText="TERMS OF EMPLOYMENT" SortExpression="ToEmp" />
<asp:BoundField DataField="JobDesc" HeaderText="DUTIES AND RESPONSIBILITIES" SortExpression="JobDesc" />
<asp:BoundField DataField="Edu" HeaderText="EDUCATION / PRC LICENSES / CERTIFICATIONS" SortExpression="Edu" />
<asp:BoundField DataField="WorkExp" HeaderText="Work Experience" SortExpression="WorkExp" />
<asp:BoundField DataField="ITSkills" HeaderText="IT SKILLS / SOFTWARE & HARDWARE PROFICIENCIES" SortExpression="ITSkills" />
<asp:BoundField DataField="OpMachines" HeaderText="OPERATIONS OF MACHINES" SortExpression="OpMachines" />
<asp:BoundField DataField="PersonalAtt" HeaderText="PERSONAL ATTRIBUTES" SortExpression="PersonalAtt" />
<asp:BoundField DataField="others" HeaderText="OTHERS" SortExpression="others" />
<asp:BoundField DataField="MinSalRange" HeaderText="Minimum Salary Range" SortExpression="MinSalRange" />
<asp:BoundField DataField="MaxSalRange" HeaderText="Maximum Salary Range" SortExpression="MaxSalRange" />
<asp:BoundField DataField="ReqByDept_Mngr" HeaderText="REQUESTED BY:" SortExpression="ReqByDept_Mngr" />
<asp:BoundField DataField="NoteBy_Bu_Head" HeaderText="NOTED BY:" SortExpression="NoteBy_Bu_Head" />
<asp:BoundField DataField="AppByHR_Mngr" HeaderText="APPROVED BY:" SortExpression="AppByHR_Mngr" />

</Fields>
</asp:DetailsView>
</div>
</div>
<div class="modal-footer">
<asp:Button ID="close2" runat="server" Text="Close" data-dismiss="modal" />
</div>
</div>
</div>
</div>









share|improve this question






















  • Your select ... query in C# doesn't depend on a parent row value / key. This is why you receive the same data for all rows. You can send a parameter into GridView1_RowCommand using CommandArgument attribute of the button.
    – Alex Kudryashev
    Nov 18 at 17:33










  • May i know how to apply it here in my code??
    – allos
    Nov 19 at 0:30













up vote
0
down vote

favorite









up vote
0
down vote

favorite











am trying to retrieve data from the database to be shown in a modal box containing a datatable with the details of the selected row. The problem im encountering seems to be that regardless of the rows i chose, the modal box showing the details only uses the first row from the database. heres the asp.net code for the gridview.



Gridview:



<asp:GridView ID="smry" runat="server" AutoGenerateColumns="False" OnRowCommand="GridView1_RowCommand" CssClass="list-group" >
<Columns>
<asp:ButtonField Text="View" CommandName="Viewdet"/>
<asp:TemplateField HeaderText="MRF No">
<ItemTemplate>
<asp:Label ID="mrfnoret" runat="server" Text='<%# Eval("MRF_No") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:BoundField DataField="BU" HeaderText="Business Unit" SortExpression="BU" />
<asp:BoundField DataField="Dept" HeaderText="Department" SortExpression="Dept" />
<asp:BoundField DataField="ReqByDept_Mngr" HeaderText="Reqested By" SortExpression="ReqByDept_Mngr" />
</Columns>
</asp:GridView>


code behind:



protected void GridView1_RowCommand(object sender, GridViewCommandEventArgs e)
{


if(e.CommandName == "Viewdet")
{


database db = new database();
string database = db.MRF();
using (SqlConnection con = new SqlConnection(database))
{
con.Open();

string query = "SELECT [MRF_No], [BU], [Dept], [PostTitle], [ReqdPrsnl], [Rank], [JobFam], [ToEmp], [JobDesc], [Edu], [WorkExp], [ITSkills], [OpMachines], [PersonalAtt], [others], [MinSalRange], [MaxSalRange], [ReqByDept_Mngr], [NoteBy_Bu_Head], [AppByHR_Mngr] FROM MRF_Details"
+ "";
using (SqlCommand com = new SqlCommand(query, con))
using (SqlDataAdapter sda = new SqlDataAdapter(query, con))
{
DataTable dt = new DataTable();
sda.Fill(dt);
details.DataSource = dt;
details.DataBind();
}
con.Close();
}

ScriptManager.RegisterClientScriptBlock(this, this.GetType(),"Pop", "openModal();", true);
}
}


Incase some are wondering i want to retrieve data from the database and show it in a modal box. here is the modal box code as well.



 <div id="TestModal" class="modal fade" role="dialog">
<div class="modal-dialog modal-lg ">
<%-- MODAL CONTENT --%>
<div class="modal-content">
<div class="modal-header">
<asp:Label class="modal-title" runat="server" Text="DETAILS" CssClass="text-pos"></asp:Label>
</div>
<div class="modal-body modalScroll">
<div class ="row next">
<asp:DetailsView runat="server" ID="details" CssClass="table" AutoGenerateRows="false">
<Fields>

<asp:BoundField DataField="MRF_No" HeaderText="MRF No" SortExpression="MRF_No" />
<asp:BoundField DataField="BU" HeaderText="BUSINESS UNIT:" SortExpression="BU" />
<asp:BoundField DataField="Dept" HeaderText="DEPARTMENT:" SortExpression="Dept" />
<asp:BoundField DataField="PostTitle" HeaderText="POSITION TITLE:" SortExpression="PostTitle" />
<asp:BoundField DataField="ReqdPrsnl" HeaderText="NO. OF REQ'D PERSONNEL:" SortExpression="ReqdPrsnl" />
<asp:BoundField DataField="Rank" HeaderText="RANK / LEVEL" SortExpression="Rank" />
<asp:BoundField DataField="JobFam" HeaderText="JOB FAMILY" SortExpression="JobFam" />
<asp:BoundField DataField="ToEmp" HeaderText="TERMS OF EMPLOYMENT" SortExpression="ToEmp" />
<asp:BoundField DataField="JobDesc" HeaderText="DUTIES AND RESPONSIBILITIES" SortExpression="JobDesc" />
<asp:BoundField DataField="Edu" HeaderText="EDUCATION / PRC LICENSES / CERTIFICATIONS" SortExpression="Edu" />
<asp:BoundField DataField="WorkExp" HeaderText="Work Experience" SortExpression="WorkExp" />
<asp:BoundField DataField="ITSkills" HeaderText="IT SKILLS / SOFTWARE & HARDWARE PROFICIENCIES" SortExpression="ITSkills" />
<asp:BoundField DataField="OpMachines" HeaderText="OPERATIONS OF MACHINES" SortExpression="OpMachines" />
<asp:BoundField DataField="PersonalAtt" HeaderText="PERSONAL ATTRIBUTES" SortExpression="PersonalAtt" />
<asp:BoundField DataField="others" HeaderText="OTHERS" SortExpression="others" />
<asp:BoundField DataField="MinSalRange" HeaderText="Minimum Salary Range" SortExpression="MinSalRange" />
<asp:BoundField DataField="MaxSalRange" HeaderText="Maximum Salary Range" SortExpression="MaxSalRange" />
<asp:BoundField DataField="ReqByDept_Mngr" HeaderText="REQUESTED BY:" SortExpression="ReqByDept_Mngr" />
<asp:BoundField DataField="NoteBy_Bu_Head" HeaderText="NOTED BY:" SortExpression="NoteBy_Bu_Head" />
<asp:BoundField DataField="AppByHR_Mngr" HeaderText="APPROVED BY:" SortExpression="AppByHR_Mngr" />

</Fields>
</asp:DetailsView>
</div>
</div>
<div class="modal-footer">
<asp:Button ID="close2" runat="server" Text="Close" data-dismiss="modal" />
</div>
</div>
</div>
</div>









share|improve this question













am trying to retrieve data from the database to be shown in a modal box containing a datatable with the details of the selected row. The problem im encountering seems to be that regardless of the rows i chose, the modal box showing the details only uses the first row from the database. heres the asp.net code for the gridview.



Gridview:



<asp:GridView ID="smry" runat="server" AutoGenerateColumns="False" OnRowCommand="GridView1_RowCommand" CssClass="list-group" >
<Columns>
<asp:ButtonField Text="View" CommandName="Viewdet"/>
<asp:TemplateField HeaderText="MRF No">
<ItemTemplate>
<asp:Label ID="mrfnoret" runat="server" Text='<%# Eval("MRF_No") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:BoundField DataField="BU" HeaderText="Business Unit" SortExpression="BU" />
<asp:BoundField DataField="Dept" HeaderText="Department" SortExpression="Dept" />
<asp:BoundField DataField="ReqByDept_Mngr" HeaderText="Reqested By" SortExpression="ReqByDept_Mngr" />
</Columns>
</asp:GridView>


code behind:



protected void GridView1_RowCommand(object sender, GridViewCommandEventArgs e)
{


if(e.CommandName == "Viewdet")
{


database db = new database();
string database = db.MRF();
using (SqlConnection con = new SqlConnection(database))
{
con.Open();

string query = "SELECT [MRF_No], [BU], [Dept], [PostTitle], [ReqdPrsnl], [Rank], [JobFam], [ToEmp], [JobDesc], [Edu], [WorkExp], [ITSkills], [OpMachines], [PersonalAtt], [others], [MinSalRange], [MaxSalRange], [ReqByDept_Mngr], [NoteBy_Bu_Head], [AppByHR_Mngr] FROM MRF_Details"
+ "";
using (SqlCommand com = new SqlCommand(query, con))
using (SqlDataAdapter sda = new SqlDataAdapter(query, con))
{
DataTable dt = new DataTable();
sda.Fill(dt);
details.DataSource = dt;
details.DataBind();
}
con.Close();
}

ScriptManager.RegisterClientScriptBlock(this, this.GetType(),"Pop", "openModal();", true);
}
}


Incase some are wondering i want to retrieve data from the database and show it in a modal box. here is the modal box code as well.



 <div id="TestModal" class="modal fade" role="dialog">
<div class="modal-dialog modal-lg ">
<%-- MODAL CONTENT --%>
<div class="modal-content">
<div class="modal-header">
<asp:Label class="modal-title" runat="server" Text="DETAILS" CssClass="text-pos"></asp:Label>
</div>
<div class="modal-body modalScroll">
<div class ="row next">
<asp:DetailsView runat="server" ID="details" CssClass="table" AutoGenerateRows="false">
<Fields>

<asp:BoundField DataField="MRF_No" HeaderText="MRF No" SortExpression="MRF_No" />
<asp:BoundField DataField="BU" HeaderText="BUSINESS UNIT:" SortExpression="BU" />
<asp:BoundField DataField="Dept" HeaderText="DEPARTMENT:" SortExpression="Dept" />
<asp:BoundField DataField="PostTitle" HeaderText="POSITION TITLE:" SortExpression="PostTitle" />
<asp:BoundField DataField="ReqdPrsnl" HeaderText="NO. OF REQ'D PERSONNEL:" SortExpression="ReqdPrsnl" />
<asp:BoundField DataField="Rank" HeaderText="RANK / LEVEL" SortExpression="Rank" />
<asp:BoundField DataField="JobFam" HeaderText="JOB FAMILY" SortExpression="JobFam" />
<asp:BoundField DataField="ToEmp" HeaderText="TERMS OF EMPLOYMENT" SortExpression="ToEmp" />
<asp:BoundField DataField="JobDesc" HeaderText="DUTIES AND RESPONSIBILITIES" SortExpression="JobDesc" />
<asp:BoundField DataField="Edu" HeaderText="EDUCATION / PRC LICENSES / CERTIFICATIONS" SortExpression="Edu" />
<asp:BoundField DataField="WorkExp" HeaderText="Work Experience" SortExpression="WorkExp" />
<asp:BoundField DataField="ITSkills" HeaderText="IT SKILLS / SOFTWARE & HARDWARE PROFICIENCIES" SortExpression="ITSkills" />
<asp:BoundField DataField="OpMachines" HeaderText="OPERATIONS OF MACHINES" SortExpression="OpMachines" />
<asp:BoundField DataField="PersonalAtt" HeaderText="PERSONAL ATTRIBUTES" SortExpression="PersonalAtt" />
<asp:BoundField DataField="others" HeaderText="OTHERS" SortExpression="others" />
<asp:BoundField DataField="MinSalRange" HeaderText="Minimum Salary Range" SortExpression="MinSalRange" />
<asp:BoundField DataField="MaxSalRange" HeaderText="Maximum Salary Range" SortExpression="MaxSalRange" />
<asp:BoundField DataField="ReqByDept_Mngr" HeaderText="REQUESTED BY:" SortExpression="ReqByDept_Mngr" />
<asp:BoundField DataField="NoteBy_Bu_Head" HeaderText="NOTED BY:" SortExpression="NoteBy_Bu_Head" />
<asp:BoundField DataField="AppByHR_Mngr" HeaderText="APPROVED BY:" SortExpression="AppByHR_Mngr" />

</Fields>
</asp:DetailsView>
</div>
</div>
<div class="modal-footer">
<asp:Button ID="close2" runat="server" Text="Close" data-dismiss="modal" />
</div>
</div>
</div>
</div>






c# asp.net gridview






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Nov 18 at 14:54









allos

134




134












  • Your select ... query in C# doesn't depend on a parent row value / key. This is why you receive the same data for all rows. You can send a parameter into GridView1_RowCommand using CommandArgument attribute of the button.
    – Alex Kudryashev
    Nov 18 at 17:33










  • May i know how to apply it here in my code??
    – allos
    Nov 19 at 0:30


















  • Your select ... query in C# doesn't depend on a parent row value / key. This is why you receive the same data for all rows. You can send a parameter into GridView1_RowCommand using CommandArgument attribute of the button.
    – Alex Kudryashev
    Nov 18 at 17:33










  • May i know how to apply it here in my code??
    – allos
    Nov 19 at 0:30
















Your select ... query in C# doesn't depend on a parent row value / key. This is why you receive the same data for all rows. You can send a parameter into GridView1_RowCommand using CommandArgument attribute of the button.
– Alex Kudryashev
Nov 18 at 17:33




Your select ... query in C# doesn't depend on a parent row value / key. This is why you receive the same data for all rows. You can send a parameter into GridView1_RowCommand using CommandArgument attribute of the button.
– Alex Kudryashev
Nov 18 at 17:33












May i know how to apply it here in my code??
– allos
Nov 19 at 0:30




May i know how to apply it here in my code??
– allos
Nov 19 at 0:30

















active

oldest

votes











Your Answer






StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");

StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














 

draft saved


draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53362200%2fhow-to-display-data-in-table-from-database-based-on-selected-row-from-gridview%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown






























active

oldest

votes













active

oldest

votes









active

oldest

votes






active

oldest

votes
















 

draft saved


draft discarded



















































 


draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53362200%2fhow-to-display-data-in-table-from-database-based-on-selected-row-from-gridview%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

"Incorrect syntax near the keyword 'ON'. (on update cascade, on delete cascade,)

Alcedinidae

Origin of the phrase “under your belt”?