Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. Web Development
  3. ASP.NET
  4. [Message Deleted]

[Message Deleted]

Scheduled Pinned Locked Moved ASP.NET
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • L Offline
    L Offline
    Lipishree
    wrote on last edited by
    #1

    [Message Deleted]

    T 1 Reply Last reply
    0
    • L Lipishree

      [Message Deleted]

      T Offline
      T Offline
      Tarun Dudhatra
      wrote on last edited by
      #2

      Hi lipi, I hope you have heard about GridView inside GridView. Just try that you can easily do that. If you haven't heard about that just go through this code, Put one GridView on aspx page with inside This master gridview put another gridview with name 'GridView2' ok Write RowBound event of GridView1(Master gridView) protected void GridView1_RowDataBound(object sender, GridViewRowEventArgs e) { GridViewRow row = e.Row; if (row.DataItem == null) { return; } GridView gv = new GridView(); gv = (GridView)row.FindControl("GridView2"); //Prepare the query for Child GridView by passing the Employee ID of the parent row DataSet ds = ChildDataSource(((DataRowView)e.Row.DataItem)["employeeID"].ToString()); gv.DataSource = ds; gv.DataBind(); } Here is the ChildDataSource Method private DataSet ChildDataSource(string strEmployeeId) { DataSet ds = new DataSet(); string Query = "Select * from Employee_Master where EmployeeId='" + strEmployeeId+ "'"; // This is my structure to access data ok just use here your code ds = dataacesslayer.SqlHelper.ExecuteDataset(DBCon.ConnectionString, CommandType.Text, Query); return ds; } And let me know is your problem solved or not? http://techiefromsurat.blogspot.com/

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups