Datagrid Columns as Row Labels ?

A

alan

Hi,

Not sure if i'm phrasing this correctly but is it possible to format my
datagrid with the colums as row labels/headers ?

I've got one record with 12 fields and rather than displaying this as
one row across a web page i want to display it as two columns (row
labels, values)

something like this:

Value
col/row A
col/row B
col/row C

thanks in advance

alan
 
C

CK

You might want to try table Html server control.
It would be something like
<table runat="server" id="tblWhatever">
<tr runat="server">
<td runat="server">FieldName</td>
<td runat="server" id="cellFieldName"><%#
DataBinder.Eval(Container.DataItem, "fieldName" %></td>
</tr>

You could build a row for each field. Just a suggestion.
~CK
 
A

alan

thanks for the quick reply...
i'm pretty new to .net so i'm just about getting to grips with the
whole dataset/datagrid thing...
i'm guessing the databinder takes care of the database side of
things...
i've also been looking at tablecounters but havent tried it out yet...

thanks again,
alan
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top