2 radiobuttonlists for selection

S

sramruttun

hi

I have 2 radiobuttonlists in my form both having more or less the same
listitems:
At Design time,
RDLGroup1 (1st radiobuttonlist) has the foll. items:
A1 A2 A3 A4 A5 (A1 is selected)

RDLGroup2 (2nd radiobuttonlist) has the foll. items:
A2 A3 A4 A5 (None is selected)

So at first, if I select A2 in RDLGroup1, then A2 should be removed from
RDLGroup2 and A1 should be added to it.
Similarly, later if I select A5 in RDLGroup1, then A5 should be removed from
RDLGroup2 and the item that was previously 'absent' should be added.
That is, each time an item is selected in RDLGroup1, then it should be
removed from RDLGroup2 and the item that was previously removed should be
added.
So I set autopostback true for RDLGroup1, and added code to do that in the
selectedindexchanged event of RDLGroup1. It works. But the postback has a
specific problem (it is not relevant here but I can explain later) so that I
can't use this postback method. I'm left with javascript. So my question is:
How can I do the removal and additions of items in the radiobuttonlists in
javascript?


Note: I'm using these 2 radiobutonlists to provide 2 level grouping for
reports. So it's obvious that if I select one item for the 1st level
grouping I can't select it again for the 2nd level grouping as well.

Any suggestions will be ok - probably some other method to achieve the above
functionality.
 
R

Ravikanth[MVP]

Hi

I think you have to user server side C# code to do this.
With Javascript it is not possible.


Ravikanth
 
S

sramruttun

thanks ravi bhai
but I think whether it is C# or VB.NET, it is server side code. (I was able
to do it using VB.NET).
It's the postback which is a problem for me, that's why I opted for
javascript.
Is there some another method to do the 2 level grouping for reports?
 

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,776
Messages
2,569,603
Members
45,189
Latest member
CryptoTaxSoftware

Latest Threads

Top