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
Radhika pawar 5Radhika pawar 5 

once checkbox is checked? how to refresh the page or how to call page load

Hi Group,

I have one requirement once i m  clicking on checkbox then  same Page automatically refreshed the Page or reload the Page or it will automatically saved on backend .

using jquey.
My Code Is :-
if (confirm("Does the School Have 1 Camp OR 2 Camps  !") == true)
                   x = "Camp 2!";
                   alert("This School has 2 follow Up Camps :"+x);
                    $("[id$=submit3]").attr("checked", false);
                  var p= $("[id$=submit2yes]").attr("checked", true);
                x ="Camp 1!";
                alert("This School has 1 Follow Up Camp :"+x);
               $("[id$=submit3]").attr("checked", true);

Thanks you,

Hello Radhika,
Please provide more details on your requirement. Not able to get the exact requirements
Radhika pawar 5Radhika pawar 5
once i m selecting the checkbox  that time its direcly save in databse.
please provide me code . for this problem

Try using <Apex:actionfunction> vf tag
In actionFunction you can define a javascript method which will invoke associated method in conrtoller.

Radhika pawar 5Radhika pawar 5
Hey Rohit plz send me the code or examle
There are two methods to do this :

1)Use @Remote Action Call to call the method

2)Use ACtion Function and call on the event

Here are the documentations for the same

Video of demo sessions

Summary :Use actionfunction if you need to maintain state between postbacks, remoteaction for stateless invocations