interviews.dotnetthread.com

↑ Grab this Headline Animator

Monday, November 24, 2008

What is the defference between <% %>,<%= %>, <%# %>?

Whenever we are going to write code inside the <% %> then that piece of code will treated as server side code generally vbscript.

when we are accessing any server side variable into the HTML(in .aspx) side then we use <%= %>.

when we are using any binding control like repeater,gridview etc then to bind the particular column with the database value then we are using <%# %> when the Autogenerate column of the binding controls are FALSE

For Example:

    Text='<%#Eval("FirstName") %>' this tag put inside the Text property of the control inside the datagrid like(textbox,label etc....)

Submit this story to DotNetKicks

No comments:

Post a Comment

Post your comments/questions/feedback for this Article.

 

Latest Articles