 |
|
 |
Hello Sir,can it possible to n number of child grid in parent grid..my urgent requirement is that parent grid and child grid but child grid must be more than 3/4 grids with full functionality like treeview grid .plz help me out sir..thanx in advance..
|
|
|
|
 |
|
 |
Please use Treeview control, or if you want to use gridview each childgridview add childgrid and same type logic that is show above.
href="http://www.tanvtech.com/Articles/MyFirstTreeviewLinqapplication.aspx
http://www.tanvtech.com/Articles/MyFirstTreeviewLinqapplication.aspx?Id=1
Tanveer
WWW.TANVTECH.COM
SOFTWARE ENGINEER
|
|
|
|
 |
|
 |
Thanks for the code.....
How to show collapsed state initially?Can u say specifically...
modified 17 Jan '12.
|
|
|
|
 |
|
 |
Thank u very much, I was looking out for this piece of code. It helped me.
|
|
|
|
 |
|
 |
Hi Ashraf
Thank you for this excellent sample.
Please explain how can we hide the children initially. I tried, by only including the parenttable data on if(!Ispostback){}.
In that case the children will never display. Please help me on this.
Thanks in advance.
Sanjana
|
|
|
|
 |
|
 |
hi ashraf...great exmple! thx.
from a previous post, you mentioned to hide children initially do the following:
In Page Load event
If(!isPostBack)
{
Bind with just parent data
}
i think i did this, but am unable to get any of the nodes to expand anytime thereafter. canyou be more specific how to accomplish this? i want to have the children hide initially, then have the nodes be able to expand/collapse the children normally. what do you mean by "Bind with just parent data?" can u b more specific? thanks!
|
|
|
|
 |
|
 |
Please give some examples on dynamic gridview with treeview..with all edit ,delete option features
hai all please clarify mny doubts
|
|
|
|
 |
|
 |
thanks
|
|
|
|
 |
|
 |
Dear Ashraf
how to hide the child directories automatically when the page was first called so, you see only the parent directory
sorry my english translation of google
|
|
|
|
 |
|
 |
In Page Load event
If(!isPostBack)
{
Bind with just parent data
}
Tanveer
WWW.TANVTECH.COM
SOFTWARE ENGINEER
|
|
|
|
 |
|
 |
Can you post a sample in vb. Thanks
|
|
|
|
 |
|
 |
no explanation of code, no insights as to how/why it work or how to customize. granted you can figure it out, but articles arent for posting just code snippets.
|
|
|
|
 |
|
 |
hey dude, thankx a ton for posting this.....
it was a gr8 help for me....
|
|
|
|
 |
|
 |
In IE6,the TreeNode Button's Text ("+" or "-") VerticalAlign is Bottom,How to Set VerticalAlign=Middle?
|
|
|
|
 |
|
 |
Check the properties of the control or use CSS to align it
Tanveer
WWW.TANVTECH.COM
SOFTWARE ENGINEER
|
|
|
|
 |
|
 |
I have download your source and run in visual studio 2008 ,but find 2 error something like: "Cn" Not Exist.
|
|
|
|
 |
|
 |
It is a connection string, please put your database conntion string there and it will work
Tanveer
WWW.TANVTECH.COM
SOFTWARE ENGINEER
|
|
|
|
 |
|
 |
Thanks!code is working now.
|
|
|
|
 |
|
|
 |
|
 |
I tested your code and has its flaws.
Something is missing, don't you think ?!
|
|
|
|
 |
|
|
 |
|
 |
protected void GridView1_RowCommand(object sender, GridViewCommandEventArgs e)
{
if (e.CommandName == "_Show")
{
int index = Convert.ToInt32(e.CommandArgument);
GridViewRow row = GridView1.Rows[index];
int G_Count = GridView1.Rows.Count;
for (int i = index + 1; i < G_Count; i++)
{
if (GridView1.Rows[i].Cells[1].Text == " ")
{
GridView1.Rows[i].Visible = true;
}
else
{
Button Bt_Min = (Button)row.Cells[0].FindControl("MinBT");
Bt_Min.Visible = true;
Button Bt_plus = (Button)row.Cells[0].FindControl("PluseBT");
Bt_plus.Visible = false;
break;
}
Button Bt_Min1 = (Button)row.Cells[0].FindControl("MinBT");
Bt_Min1.Visible = true;
Button Bt_plus1 = (Button)row.Cells[0].FindControl("PluseBT");
Bt_plus1.Visible = false;
}
}
if (e.CommandName == "_Hide")
{
int index = Convert.ToInt32(e.CommandArgument);
GridViewRow row = GridView1.Rows[index];
int G_Count=GridView1.Rows.Count;
for (int i = index+1; i < G_Count; i++)
{
if (GridView1.Rows[i].Cells[1].Text == " ")
{
GridView1.Rows[i].Visible = false;
}
else
{
Button Bt_Min = (Button)row.Cells[0].FindControl("MinBT");
Bt_Min.Visible = false;
Button Bt_plus = (Button)row.Cells[0].FindControl("PluseBT");
Bt_plus.Visible = true;
break;
}
Button Bt_Min1 = (Button)row.Cells[0].FindControl("MinBT");
Bt_Min1.Visible = false;
Button Bt_plus1 = (Button)row.Cells[0].FindControl("PluseBT");
Bt_plus1.Visible = true;
}
}
Tanveer
|
|
|
|
 |
|
|
 |
|
 |
Yes the result is displyed
Tanveer
|
|
|
|
 |
|
 |
Thank you,
Is it updated to include the omission noted above?
|
|
|
|
 |