Reply
Regular Contributor
ramya1
Posts: 27
0

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

Moderator
Ankit_Arora
Posts: 1,767
0

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

Why don't you use radio buttons?

 

Thanks

Ankit Arora

Blog | Facebook | Blog Page

Force.com MVP
Certified Developer | Twitter


Don't forget to give KUDOS if post helped you.


Latest Blog Posts : Streaming API- Easy Code AND Uploading Multiple Attachments into Salesforce - Simple Code


If a reply to a post answers your question or resolves your problem, please mark it as the solution to the post so that others may benefit.
Regular Contributor
ramya1
Posts: 27
0

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

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..

Moderator
Ankit_Arora
Posts: 1,767
0

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

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

Force.com MVP
Certified Developer | Twitter


Don't forget to give KUDOS if post helped you.


Latest Blog Posts : Streaming API- Easy Code AND Uploading Multiple Attachments into Salesforce - Simple Code


If a reply to a post answers your question or resolves your problem, please mark it as the solution to the post so that others may benefit.