views:

128

answers:

2

Hello,

My question is: Can I add in new column(S) in the gridview if the column is not found in the database? - E.g. An indicator if a certain lecturer is a ML/Lec (roles).

I have a gridview that is "extracted" out from the database. But I want to add in a new row which is not in the database but links to the data in the database. For example, in the database, I know that a certain lecturer is a module leader, staff. But I want to have an extra column which can indicate in itself (probably a tick/mark) that the following name (prev column) is a module leader or staff; and i am not allowed to add new column in the database.

Any help appreciated. Need me to further explain my queries, let me know. :)

A: 

What you're really looking for is a way to add columns to a gridview when autogeneratecolumns=true..

http://stackoverflow.com/questions/686544/any-way-to-manipulate-the-columns-in-gridview-with-autogeneratecolumns-true

madcolor
Hello madcolor,erm not really. my autogeneratecolumns is set to false. Husna
Nana
A: 

Could you not add a column to the dataset that comes from the database, rather than the actual table. Then fill it with the calculated vaule.

Andrew Cox