DataBinding images using Repeater Control. Is there an ImageField column?

C

Charlie@CBFC

Hi:

Is it possible to databind an image in Repeater Control? I see support for
it in GridView, but not in Repeater control. There is another way to do
this, but would rather go with new controls.

Thanks,
Charlie
 
D

dkode

In the past when I have had the need to do this, the easiest way is to
put a placeholder in your repeater, then in the ItemDataBound event,
manually add a System.Web.Image control into the placeholder.

Perhaps someone has an easier way/more effecient way, I've always used
that method in the past.

Hope this Helps!

Sean
 
E

Eliyahu Goldin

Charlie,

You can use databinding expression in item template to databind any
properties of any controls. Did you try?
 
C

Charlie@CBFC

Yeah but image control only binds to a url. My images are stored in
database in binary fields. It can be done with an HTTP handler.

Charlie

Eliyahu Goldin said:
Charlie,

You can use databinding expression in item template to databind any
properties of any controls. Did you try?

--
Eliyahu Goldin,
Software Developer & Consultant
Microsoft MVP [ASP.NET]


Charlie@CBFC said:
Hi:

Is it possible to databind an image in Repeater Control? I see support
for it in GridView, but not in Repeater control. There is another way to
do this, but would rather go with new controls.

Thanks,
Charlie
 

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,744
Messages
2,569,483
Members
44,902
Latest member
Elena68X5

Latest Threads

Top