开发者

asp.net 3.5. grid view - visible="false" controls not getting value when calling update statement

in asp.net 3.5[vs2008] Gridview i got one issue. i have binded objectdatasource with datagridview, provided Get and Update method in ojectdatasource . and in gridview i made some Bound fields visible ="false"[e.g. Primary Ke,Id, foregin 开发者_C百科Key fields which i need at time of update]. but when i did debugging, i am not getting values for fields which i made visible="false" in updatemethod.

i used 3-tier architecture and passing Businessobject from DAL to BAL to UI and UI to BAL to DAL.

so please can anyone suggest me that if i want some fields which are for coding puporse and should not be displayed to users. what is the method to do it in GridView?


Add your primary key and foriegn key column names to the GridViews's DataKey property.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜