FormView and HTMLEncode

M

Mathieu Pagé

Hi,

I'm trying to display some informations on a web page into a FormView.
My data are bound using the ObjectDataSource Object. Everything is
working fine, except I can't find how to HTMLEncode some
fields before they are displayed.

I tried to replace this :

<% Bind("field") %>

by this :

<% Server.HTMLEncode(Bind("field")) %>

But it does not work, saying Bind is not declared.

I have searched on Google and Google Groups and found some reference to
a HTMLEncode property, but this seem to apply to DataGrid fields only.

Is there a way to HTML encode a string before it get used in a FormView?

Mathieu.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,066
Latest member
VytoKetoReviews

Latest Threads

Top