9 votes
Accepted

actionfunction is returning null parameter value

When we need to send parameter with action function then we have to use rerender attribute in otherwise we always get null value in controller. <apex:actionFunction name="setAttachment" action=...
user avatar
  • 1,905
9 votes
Accepted

Visualforce: Dynamically ReRender a row within <apex:repeat> by passing $Component through controller

Through attempting this same problem on another project I was able to get a fresh look at the issue. What I learned through countless testing is that rerender attribute can be very tricky. For example:...
user avatar
  • 4,368
6 votes
Accepted

How to disable a apex command button

You should set the btnDisabled class name, as well as setting "disabled". Here's a live example for you to use: <apex:page standardStylesheets="true" lightningStylesheets="false" showHeader="true" ...
user avatar
  • 430k
5 votes
Accepted

pressing enter on inputText does not trigger commandButton

Catch the enter-key at your inputText with the onkeypress-handler and trigger a fake-click on the button: <script> function handlerKeyPress(ev) { if (window.event && window....
user avatar
  • 33.5k
5 votes
Accepted

commandbutton not running action function after reRender

Pretty sure it is related to this issue/bug re Command Buttons and Action Regions. I just tried a short version of your code with the button wrapped in an actionregion, and it then worked for me.
user avatar
5 votes
Accepted

apex:actionFunction with apex:param Param not setting

Found out what the problem was and thought I'd post it here in case anyone else has the same issue. Because the start and end were objects (moment), they weren't casting properly to the controller ...
user avatar
  • 442
5 votes
Accepted

apex:commandButton updated by apex:actionFunction

One way use action status. Display loading symbol unit your process is not completed. <apex:actionFunction action="{!startRequest}" name="startRequest_JS" ...
user avatar
5 votes
Accepted

Used html button instead of apex command button,controller action not updating new values?why

Values from your page are sent to a controller on form submit. You can see this if you view HTML code generated by your visualforce page <apex:commandButton/> will be an input with type="submit"....
user avatar
  • 2,111
5 votes
Accepted

<apex:actionFunction> may not be used within an iterable component

You need to move your action function outside your iteration block and call it via Javascript by passing the parameter. So before your iteration put this: <apex:actionFunction action="{!...
user avatar
5 votes

visualforce page ActionFunction reRender not Working

You can absolutely rerender the <use>and <svg> tag by: The xmlns= on the div containing the SVG is a MUST as if you try to rerender without it the page will simply stall. Important trick ...
user avatar
  • 53.1k
5 votes
Accepted

apex:input with oncomplete

You need to actually invoke the function for onchange attributes by using parentheses (()). No Good <apex:input onchange="someMethod" ... /> Good <apex:input onchange="someMethod();" ... /...
user avatar
  • 142k
5 votes
Accepted

ActionFunction not working properly.Values not getting passed to controller

add rerender attribute in your actionFunction, like this rerender='none'. It is a known issue in Salesforce that if you are not using rerender, then your actionFunction may not work properly.
user avatar
5 votes
Accepted

apex:actionFunction not passing the parameters

Action function is required to have rerender attribute set so that it posts payload back to server. So something like this should work. <apex:actionFunction name="Sign_Up" action="{!SignUp}" ...
user avatar
  • 1,662
4 votes
Accepted

Javascript action function not working after Summer 14 release

This is how you would make sure you are using jQuery (in this case taken from a CDN location): <apex:includeScript value="https://code.jquery.com/jquery-1.11.0.min.js"/> <script> var j$ = ...
user avatar
  • 129k
4 votes

How to create tabs for an apex:tabPanel dynamically with apex:repeat and rerender?

Unfortunately you can't use the apex:tabPanel with the apex:repeat as you tried: apex:repeat This component can't be used as a direct child of the following components: <apex:panelBar>...
user avatar
  • 33.5k
4 votes
Accepted

apex:selectList always passing older value on onchange..?

It's because your reference twice hr.projectVal, that's why it's getting confused, one in your select and one in your param. Remove your param and it should fix your problem, it's useless. Update ...
user avatar
  • 5,478
4 votes
Accepted

Action function not rerendering

You cannot rerender an element if it has a conditional render attached to it and the condition will not rerender so its state will remain the same (shown or hidden depending on the condition). You ...
user avatar
  • 53.1k
4 votes

OnComplete Javascript to pop up alert and Redirect to a record page

So when you create the script and use the binding the value of the binding is the what it was when the page loads. If all you wanted to do was redirect to the new case (without a message) that is ...
user avatar
  • 53.1k
4 votes

Visualforce actionFunction not working when used with jQuery

JavaScript is case-sensitive. In one function name, you've got an uppercase C and in another you've got a lowercase c. The name attribute on the <apex:actionFunction tag is used as the name of the ...
user avatar
  • 22.3k
4 votes
Accepted

Can apex:param pass null for Integers?

It looks like the problem is that when the parameter comes over as an empty string, salesforce converts the value to 0 instead of NULL. You could consider setting the value of index in your method ...
user avatar
  • 12.2k
4 votes

Why actionFunctions are not as fast as RemoteAction

In the thread @sfdcfox have provided several good points.Posting some of them which are related to your answer: @RemoteAction methods require less bandwidth, and server processing time, because only ...
user avatar
  • 5,714
4 votes
Accepted

Apex:param not sending parameter in actionFunction

I have had mixed luck doing it like that (probably my own fault). However I know this works (string values): public string paramValue {get;set;} public pagereference AttachFile(){ system....
user avatar
  • 53.1k
4 votes

action callback from apex controller a.getReturnValue() is empty

You need to mark the properties of the inner class as @AuraEnabled for them to be returned. This is likely why you are seeing a null return value (there is no visible data to return). Note that you ...
user avatar
  • 3,942
4 votes
Accepted

apex:actionsupport event not firing

You have to nest the <apex:actionSupport> tag within the tag whose action you are trying to support. You have it inverted. Correct <a ...> <apex:actionSupport ... /> </a> ...
user avatar
  • 142k
4 votes
Accepted

Call 2 methods on page load

You're missing rerender in your apex:actionFunction, without which whole page would reload. Your JavaScript code looks fine. Have a dummy apex:OutputPanel for rerendering. I suspect your second ...
user avatar
  • 17.5k
4 votes
Accepted

Action Function Param Not Passing to Controller

Salesforce has built the framework for apex:actionFunction like that way that it expects rerender attribute to pass value to the controller and the ID of one or more components that are redrawn when ...
user avatar
4 votes
Accepted

Using Param in ActionFunction - Unexpected Token ':'

You need to specify a name attribute, or you would get unexpected behavior. <apex:param name="aValue" value="" assignTo="{!variableFromVfp}"></apex:param>
user avatar
  • 430k
3 votes
Accepted

How to use ActionSupport, ActionREgion, ActionFunction all together

You can try to use your action method and reRender parameter directly from the actionSupport. And wrap your list with an actionRegion. You then don't need an extra javascript function and ...
user avatar
  • 21.7k
3 votes
Accepted

Call two controller method from a single comandbutton click

The simplest and legitimate way to do this is by calling getprev method at the end of AddMore Something like this: public void AddMore() { //count = count+1; ...
user avatar
  • 8,979
3 votes

Upload a file using <apex:actionFunction> integrated with JQuery

In order to get files from jQuery to Apex, what you can do is use the REST-Api. The REST-Endpoint looks something like this: @RestResource(urlMapping='/FileUpload/v1/*') global class ...
user avatar
  • 641

Only top scored, non community-wiki answers of a minimum length are eligible