什么是之间和LT的差异; #eval和< #bind在asp.net [英] What's the difference between <#eval and <#bind in asp.net

查看:150
本文介绍了什么是之间和LT的差异; #eval和< #bind在asp.net的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在一个gridview,我们可以使用<%#评估和演示%GT; <%#绑定%GT; 来从数据库输出值。它们之间的区别是什么?

In a gridview, we can use <%#Eval%> or <%#Bind%> to output values from a database. What is the difference between them?

推荐答案

评估是一种方法绑定,绑定是双向

EVal is one way binding, Bind is two way

如果您绑定使用eval的值,它是只喜欢读。您只能查看数据。

If you bind a value using Eval, it is like a read only. You can only view the data.

如果您绑定使用绑定的值,如果你这样做的价值有所改变,将反映在数据库中还

If you bind a value using Bind, and if you do some change on the value it will reflect on the database also

您可以看到类似的帖子在这里堆栈溢出

you can see similar post here on stack overflow

<一个href=\"http://stackoverflow.com/questions/259141/difference-between-bind-and-eval\">http://stackoverflow.com/questions/259141/difference-between-bind-and-eval

这篇关于什么是之间和LT的差异; #eval和&lt; #bind在asp.net的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆