Friday, February 09, 2007

ASP.NET 2.0 - Some Basic Things To Remember

- When you want to use simple binding with no evaluation:

# Bind("MyFieldName")

- When you want to use evaluation, for example a value against a protected method, use:

# IsLead(Eval("Lead"))

Code behind:
protected string IsLead(object val)
{
if (val.ToString() == "True")
return "Yes";
else
return String.Empty;
}

No comments:

Fixes to common .NET problems, as well as information on .NET features and solutions to common problems that are not language-specific.

Fixes to common .NET problems, as well as information on .NET features and solutions to common problems that are not language-specific.

Z