Formatting

E

Evan Camilleri

In ASP.NET using

<%# DataBinder.Eval(Container, "DataItem.R") %>

I need that if DataItem.R = 0 then nothing (not even a zero) will be
displayed.
 
P

Patrick.O.Ige

Evan you should be able to get the DataItem in ITEMDATABOUND
and there do whatever you would like to do
Patrick
 
K

Karl Seguin

To elaborate on Patrick's post, you have two options. Do the formatting
inline, or in the ItemDataBound. Typically, hooking up the ItemDataBound,
while a bit more work, provides you with cleaner code and greater
flexibility. You can see some detailed examples of both these methods at:
http://openmymind.net/index.aspx?documentId=8#4

Karl
 

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,755
Messages
2,569,537
Members
45,021
Latest member
AkilahJaim

Latest Threads

Top