Showing posts with label grid. Show all posts
Showing posts with label grid. Show all posts

Saturday, March 31, 2012

Table to Grid

How to bind a grid using table?
I've a table and I want to see that data in a grid for sorting and
pagination. Please provide an example.

Thanks,
XDi think you are talking about the datatable,

you must fill a dataset first, then call this,

Datagrid1.Datasource = ds.Tables(0)
Datagrid1.Databind();

This will show the data in your datagrid, also make sure that you turn on
the check in autogenerate columns in Datagrid Property Builder

"SK" wrote:

Quote:

Originally Posted by

How to bind a grid using table?
I've a table and I want to see that data in a grid for sorting and
pagination. Please provide an example.
>
Thanks,
XD
>
>
>


No it is not datatable. It is normal web.UI.webcontrols.Table
I want to view the data in gridview1 than a table.

- Thanks

"Murtaza" <Murtaza@.discussions.microsoft.comwrote in message
news:9C7365A4-7AC3-497D-B383-02D9F700F1C9@.microsoft.com...

Quote:

Originally Posted by

>i think you are talking about the datatable,
>
you must fill a dataset first, then call this,
>
Datagrid1.Datasource = ds.Tables(0)
Datagrid1.Databind();
>
This will show the data in your datagrid, also make sure that you turn on
the check in autogenerate columns in Datagrid Property Builder
>
"SK" wrote:
>

Quote:

Originally Posted by

>How to bind a grid using table?
>I've a table and I want to see that data in a grid for sorting and
>pagination. Please provide an example.
>>
>Thanks,
>XD
>>
>>
>>


Then again you have to follow same approach, construct a datatable, Iterate
through every row of ur HTML table n fill that Datatable then bind that
Datatable to ur gridview...

"XD" wrote:

Quote:

Originally Posted by

No it is not datatable. It is normal web.UI.webcontrols.Table
I want to view the data in gridview1 than a table.
>
- Thanks
>
"Murtaza" <Murtaza@.discussions.microsoft.comwrote in message
news:9C7365A4-7AC3-497D-B383-02D9F700F1C9@.microsoft.com...

Quote:

Originally Posted by

i think you are talking about the datatable,

you must fill a dataset first, then call this,

Datagrid1.Datasource = ds.Tables(0)
Datagrid1.Databind();

This will show the data in your datagrid, also make sure that you turn on
the check in autogenerate columns in Datagrid Property Builder

"SK" wrote:

Quote:

Originally Posted by

How to bind a grid using table?
I've a table and I want to see that data in a grid for sorting and
pagination. Please provide an example.
>
Thanks,
XD
>
>
>


>
>
>

Wednesday, March 28, 2012

tables & rows & columns

I have a table that doesn't line up the way I want it to. I have 6 rows and
3 columns. The 3rd column spans the 6 rows and contains a grid. If the
data in the grid has more than 6 rows of data, the other rows spread out
vertically, as if there is extra space in there. I don't want that to
happen, I want the 6 rows to be together as if there is no space between
then. I have tried using height, valign, using a set height and using a
percentage height and it doesn't work. How can I make the 6 rows on the
left align all the way to the top?
<table borderColor=red cellSpacing=0 cellPadding=0 width="100%" border=1
runat="server" ID="Table1">
<tr vAlign=top colspan=4><td> </td></tr>
<tr vAlign=top>
<td valign=top style="HEIGHT: 15px" align=left width=100>Col 1</td>
<td vAlign=top height=5>Col 2</td>
<td align=right rowspan=6>Col 3<br>Col 3<br>Col 3<br>Col 3<br>Col 3<br>Col
3<br>Col 3<br>Col 3<br>Col 3<br>Col 3<br>Col 3<br>Col 3<br>Col 3<br>Col
3<br>Col 3<br>Col 3<br>Col 3<br>Col 3<br>Col 3<br>Col 3<br>Col 3<br></td>
<td align=left rowspan=6>Col 4</td></tr>
<tr valign=top height=1>
<td valign=top>col 1</td>
<td valign=top>col 2</td>
</tr>
<tr valign=top height=1>
<td valign=top>col 1</td>
<td valign=top>col 2</td>
</tr>
<tr valign=top height=1>
<td valign=top>col 1</td>
<td valign=top>col 2</td>
</tr>
<tr valign=top height=1>
<td valign=top>col 1</td>
<td valign=top>col 2</td>
</tr>
<tr valign=top>
<td valign=top>col 1</td>
<td valign=top>col 2</td>
</tr>
</table>Maybe I didn't really get your question, but I do not see a grid in the
3rd column.
But did you try to put another table into one cell? That often works.
Remy Blaettler
www.collaboral.com

tables & rows & columns

I have a table that doesn't line up the way I want it to. I have 6 rows and
3 columns. The 3rd column spans the 6 rows and contains a grid. If the
data in the grid has more than 6 rows of data, the other rows spread out
vertically, as if there is extra space in there. I don't want that to
happen, I want the 6 rows to be together as if there is no space between
then. I have tried using height, valign, using a set height and using a
percentage height and it doesn't work. How can I make the 6 rows on the
left align all the way to the top?

<table borderColor=red cellSpacing=0 cellPadding=0 width="100%" border=1
runat="server" ID="Table1">
<tr vAlign=top colspan=4><td> </td></tr
<tr vAlign=top>
<td valign=top style="HEIGHT: 15px" align=left width=100>Col 1</td>
<td vAlign=top height=5>Col 2</td>
<td align=right rowspan=6>Col 3<br>Col 3<br>Col 3<br>Col 3<br>Col 3<br>Col
3<br>Col 3<br>Col 3<br>Col 3<br>Col 3<br>Col 3<br>Col 3<br>Col 3<br>Col
3<br>Col 3<br>Col 3<br>Col 3<br>Col 3<br>Col 3<br>Col 3<br>Col 3<br></td>
<td align=left rowspan=6>Col 4</td></tr>
<tr valign=top height=1>
<td valign=top>col 1</td>
<td valign=top>col 2</td>
</tr>
<tr valign=top height=1>
<td valign=top>col 1</td>
<td valign=top>col 2</td>
</tr>
<tr valign=top height=1>
<td valign=top>col 1</td>
<td valign=top>col 2</td>
</tr>
<tr valign=top height=1>
<td valign=top>col 1</td>
<td valign=top>col 2</td>
</tr>
<tr valign=top>
<td valign=top>col 1</td>
<td valign=top>col 2</td>
</tr
</tableMaybe I didn't really get your question, but I do not see a grid in the
3rd column.
But did you try to put another table into one cell? That often works.

Remy Blaettler
www.collaboral.com

Tables and Design

I am using a table in grid layout and position my controls where I want them. Does anyone know why when I view it in a browser my controls are not positioned like the way I have them in design view. Some images are overlapping other images.

post your html table code here.

Tuesday, March 13, 2012

TASK MENU

I see on some text a task menu pop up next to a dropdownlist or a grid view for choosing a datasource and setting certain properties. I try but fail to make the task menu appear. Please explain how. Thanks.

In design mode, hover over a control that has quicktasks (datasource,dropdown,etc..)
a small triangle appears above the control - click it to open quicktasks