Hi everyone, I was just wondering why this won't work, more specifically why the replace function won't work

<%# DataBinder.Eval(Container.DataItem, "name").ToString().Replace("&","&amp;") %>

Thanks

Please verify the name of dataitem.

<%# DataBinder.Eval(Container.DataItem, "name").ToString().Replace("&","&amp;") %>
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.