Solved

Radiobutton in listview

Posted on 2011-03-07
3
1,214 Views
Last Modified: 2012-05-11
Helllo folks I need some help.
I've a listview with a radiobutton (single), then run my page, and when I select one radiobutton, I can select all the other radiobutton in the listview. So I can have all selected and that's impossible.
I tried everything.

Here is my code

Thanks in advanced for any help
<asp:ListView ID="lvOfrendas" runat="server" DataSourceID="odsOfrendas" EnableModelValidation="True">
        <EmptyDataTemplate>
            <span><br /></EmptyDataTemplate>
        <LayoutTemplate >
            <asp:PlaceHolder id="itemPlaceholder" runat="server" />
        </LayoutTemplate>          
        <ItemTemplate>     

             <label>
                 <asp:HiddenField ID="HiddenImgId" Value='<%# eval("ImgIdCyO") %>' runat="server" />
                
                 <asp:RadioButton ID="rb_img"  GroupName="of"   value='<%# eval("ImgIdCyO") %>' runat="server"  />
                 
                 <asp:Image ID="Img_Ofrenda" ImageUrl='<%# "../imagenes/" & eval("ImgNombre") %>' runat="server" />
             </label>

        </ItemTemplate>
    </asp:ListView>

Open in new window

0
Comment
Question by:nkoriginal
3 Comments
 
LVL 5

Accepted Solution

by:
Kelmen earned 500 total points
ID: 35063586
10 radio buttons with 1 single same groupname, you only can pick 1
if you want to be able to select all 10, they need to have different groupname

use different groupname, and i believe you need more code to validate and properly manage them.

0
 
LVL 19

Expert Comment

by:Amandeep Singh Bhullar
ID: 35944471
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

IntroductionWhile developing web applications, a single page might contain many regions and each region might contain many number of controls with the capability to perform  postback. Many times you might need to perform some action on an ASP.NET po…
Problem Hi all,    While many today have fast Internet connection, there are many still who do not, or are connecting through devices with a slower connect, so light web pages and fast load times are still popular.    If your ASP.NET page …
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now