473,499 Members | 1,653 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

DataList with RadioButtons + Images: How to click on the images to activate the radiobutton?

I have a DataList, which looks a bit like this:
<asp:DataList id="dlstCheeseType" runat="server"
RepeatColumns="4" RepeatDirection="Horizontal"
ShowHeader="False" ShowFooter="False"
ItemStyle-VerticalAlign="Top" ItemStyle-HorizontalAlign="Center"
ItemStyle-Width="25%" Width="100%">
<ItemTemplate>
<asp:RadioButton ID="cheeseChoice" Text='<%#
Container.DataItem.Row("CheeseName") %>' Runat="server"
GroupName="cheeseGroup"/>
<br>
<asp:Image id=imgCheese Runat="server"
ImageUrl='<%# "Images/" & Container.DataItem.Row("CheeseImg") %>'
Width="100px" Height="100px">
</asp:Image>
</ItemTemplate>
</asp:DataList>
(sorry for the formatting ;))

Basically it's filled with a bunch of choices from the database, with a Name
and a graphic. The user should be able to choose one of them using the radio
button (that doesn't work properly, but that's a different question ;)).

My question:
How can I add something to allow the user to click on the images and
activate the RadioButtons that way? (preferably something client-side, i.e.
without posting the full form to the server)

Thanks!

Nov 19 '05 #1
0 982

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
3065
by: V. Jenks | last post by:
What seems like a simple thing is apparently not so straightforward? I have a datalist. Inside of that datalist is an <itemtemplate> secion which contains other server controls such as a...
1
1803
by: Christiaan Nieuwlaat | last post by:
Hi everyone, Could you please help me with this? I need to create a table in which resultdata from a sql server table can be shown and/or edited by using controls, for instance the radiobutton....
2
1232
by: Hrvoje Vrbanc | last post by:
Hi all! I have a DataList with fixed number of columns and variable number of rows (depending of the number of rows in the database). Now, I'd like to put a RadioButton control in every DataList...
11
4635
by: Rourke Eleven | last post by:
I have looked and searched. What good is the databind property on Radiobuttons? How does one go about actually using it? What is a good resource on this? I understand that I can easily get/set...
3
5377
by: Sourav Dutta Gupta | last post by:
I am having some problem regarding radiobutton inside a datalist. I want to have a radiobutton on each row of my datalist. I want to check a particular button, all the other would remain unchecked....
4
2084
by: news.microsoft.com | last post by:
Hello, I have two databound radiobuttons which have advanced databinding properties of onpropertychanged enabled so that I can raise the columnchanged event whenever the radiobuttons are...
16
12128
by: Vikas Kumar | last post by:
i am selectin some data from database and through reader showing it in datalist as above now for radio buttons i have single column which returns 1,2,3 and according to that i want one of above...
1
2243
by: David Lozzi | last post by:
Howdy, Using ASP.NET 2.0 with VB. I have a datalist that is listing out options. Ecah option has a radio button for which the user has to select only one option from the list. It displays...
0
1240
by: =?Utf-8?B?Vmlua2k=?= | last post by:
Hello Everyone, I am having this problem. I have this datalist and whenever I expand the datalist by the plus button, it overlaps other controls on my web page and sometimes these controls come...
0
7131
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7007
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7220
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
5470
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
4600
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3099
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
1427
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
665
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
297
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.