function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
ramya1ramya1 

Generate an error message when more than one check box was selected

Hi,

 

I have a visual force page which display multiple records with check box's.

I  need to allow the user to select only one check box at a time.If they are trying to select a another check box should display a alert saying that u r allowed to check only one record at a time.

 

I am trying to map all the fields of a record when the checkbox is selected....I want to generate an error message when more than one record was selected... 

 

Thanks in advance

Ankit AroraAnkit Arora

Why don't you use radio buttons?

 

Thanks

Ankit Arora

Blog | Facebook | Blog Page

ramya1ramya1

Thanks for your post...

 

But the checkbox that am trying to use is a custom field on PageBlockTable on Page...Can you please suggest me the way how to use radio buttons instead of Checkboxes....

 

Thanks in advance..

Ankit AroraAnkit Arora

Show radio on pageblocktable rather using input fields and use wrapper class and bind the values in it.

 

Thanks

Ankit Arora

Blog | Facebook | Blog Page