Questions tagged [actionfunction]

A component that provides support for invoking controller action methods directly from JavaScript code using an AJAX request. An <apex:actionFunction> component must be a child of an <apex:form> component.

Filter by
Sorted by
Tagged with
1 vote
1 answer
71 views

Switching from @remoteaction to actionFunction due to "Visualforce Remoting Exception: Input too long" error

In very few words, I am hitting some sort of limit with a visualforce remote action, as I get the following error: Visualforce Remoting Exception: Input too long I reached out to Salesforce support, ...
user avatar
  • 305
0 votes
1 answer
41 views

Will the use of apex:actionFunction result in a CSRF vulnerability?

I need the record to be updated when the visualforce page loads. In the apex:page tag, I utilised the action property to invoke the apex method that executes update DML. Salesforce considers an onload ...
user avatar
  • 1
2 votes
1 answer
45 views

ActionFunction in custom component wrapped in repeater?

I've been having a problem with some of my code. I won't post the whole code, since the page is quite complex, but here's a simplified version. Essentially I have a visualforce page "TestPage&...
user avatar
0 votes
1 answer
103 views

Javascript visualforce upload file issue

I'm attempting to upload a file through a VF command link and action function [working on old unmanaged package :-( ]. For multiple rows in pageblocktable. I am having trouble deciding the id for each ...
user avatar
  • 3,102
0 votes
1 answer
109 views

How to stop execution of apex:actionFunction on the basis of condition

I am calling two action functions one after the other. In first action function I am doing DML operation and in second action function i am calling API method. I want to stop execution of second ...
user avatar
0 votes
1 answer
136 views

Example for setBackground() method

I am trying to find an good example for setBackground() method on the action object, but came up with a code snippet that seems to be having lesser details. https://developer.salesforce.com/docs/atlas....
user avatar
  • 6,634
1 vote
0 answers
79 views

Visualforce page apex:actionfunction form validation

I have an action function that is being used to call a save method on controller which is reloading page. When I call this save method from a command button, there is a validation on the form fields ...
user avatar
  • 888
0 votes
1 answer
90 views

Conditionally navigate from apex:actionFunction

We have an apex:actionFunction like so: <apex:actionFunction name="communityLogin" action="{!login}"> <apex:inputHidden value="{!username}" id="...
user avatar
1 vote
1 answer
114 views

Is it possible for one Visualforce Page / Apex Class to modify of another instance of itself?

I have an apex class mySenderClass with public {get;set;} variables that store values such as subject and HTML Body that I use in a Messaging.sendEmail method. Users open multiple tabs of the same VFP ...
user avatar
  • 1,838
1 vote
0 answers
98 views

Unable to use rerender and oncomplete with apex:input file

I have checked that apex:inputfile does not work with rerender and oncomplete tags of action function. But I have seen there are some workaround. I tried using action region around other content, like ...
user avatar
1 vote
1 answer
285 views

apex action function not calling controller method

I am calling the controller method from action function but it is not getting called from the action function. Please review the below code. Visualforce Page <apex:outputPanel id="...
user avatar
0 votes
1 answer
86 views

unable to update boolean variable with actionfunction

I'm trying to update the boolean value named selected in wrapper class action support and onclick functions. Here is my code. Please let me know how to handle this <apex:outputPanel id="table2&...
user avatar
  • 1,430
0 votes
1 answer
22 views

Can't get my component button to create a record and ideally get the Id back

Back again! Any help is greatly appreciated. I have a 'Save' button on my Component that calls an apex class which is supposed to create a record in a DML statement. I am not seeing any errors on the ...
user avatar
2 votes
1 answer
323 views

action.setCallback not executing to pass data back to component

Trying to get my head around coding in general so full disclaimer i'm new as they come! What I am trying to achieve is to pass an ID using force:hasRecordId on the aura:component to an APEX CLASS (...
user avatar
1 vote
0 answers
67 views

Process Builder or Workflow Updating Addresses "Country" based on "state/province"

Does anyone have experience creating a workflow where if the "State/Province" is (ex. IN, VI, MT, etc.) to auto-fill the country? I'm trying to prevent inconsistancies with Country spelling or Users ...
user avatar
0 votes
1 answer
82 views

Using Param in ActionFunction - Unexpected Token ':'

Using a simple action function and param to pass a value to a controller, but receiving the following in the browser. Uncaught SyntaxError: Unexpected token ':' Exception caught on ':' in ...
user avatar
  • 1,838
0 votes
1 answer
2k views

How to Add spinner to SLDS VF page when button is clicked

I must be missing something here because the spinner does not show up, but not sure where the problem is. What am I missing? <li class="slds-button-group-item"> <apex:commandButton ...
user avatar
  • 337
0 votes
0 answers
91 views

OnChange input picklist field page message is not showing

I am writing a VF page where my requirement is that I have a input picklist field. When I change the picklist value it is calling to controller method. And when in controller I have written a page ...
user avatar
  • 634
0 votes
1 answer
376 views

Action Function On Complete Event

I have a VF Page where one link is to generate email of current detail page content. Once the email has been triggered to the user we need to show pop-up msg that the email has been sent. So i have a ...
user avatar
1 vote
1 answer
39 views

My Action Function is not Working with java script [closed]

Action Function not working. My apex code and visualforce page here below- public class BBH_Survey { public String Survey_res {get;set;} Public BBH_Survey() { CasId='...
user avatar
0 votes
1 answer
348 views

calling to the server with actionfunction and settimeout

I have a search input on VF page which every character that printed on the keyboard will show the closest result, using actionFunction. for example : If I printed "uni" all accounts that they names ...
user avatar
  • 959
0 votes
1 answer
32 views

ActionFunction is loosing letters when making a dynamic search

I have a search input which every character that printed on the keyboard will show the closest result, using actionFunction. for example : If I printed "uni" all accounts that they names include the ...
user avatar
  • 959
1 vote
1 answer
32 views

How to adress rerender in visualforce page on pageload

I currently use the actionregion to rerender an image based on the input of a picklist field. This works by showing the image if I select the correct value in the picklist field. How do I do an ...
user avatar
  • 2,090
1 vote
1 answer
134 views

Action Function nulling out values unless rerender is specified?

I have the following part in my visualforce page: <apex:form> <apex:actionFunction name="interestInShowConfirmed" action="{!interestInShowConfirmed}" /> <apex:actionFunction ...
user avatar
0 votes
0 answers
81 views

rerender does not work when the outputPanel id is made unique

<apex:page id="idPageComponent" standardController='Case' extension='testController'> <apex:form id="idForm"> <apex:actionFunction name="testMethod" action="{!testMethodDetails}" ...
user avatar
0 votes
1 answer
269 views

Selectoption value is not passed to controller

Status picklist values are : New,Pending,Closed. In onchange i am trying to pass selected picklist value . If i select New/Pending/Closed the value is passed to controller .But when i chose the ...
user avatar
  • 29
1 vote
1 answer
431 views

HTML Editor Action Button

I am looking to create a form within HTML Editor with a submit button. From what I am reading, no functionality is available within HTML Editor. Can anyone confirm that this is correct? UPDATES:...
user avatar
  • 3,179
0 votes
2 answers
581 views

Second apex method executing before the first one finishes

I have a vf page displaying several Multi select custom buttons. And I am calling a apex method every time one of the button is clicked from VF page using actionfunction. But if I click 2 buttons in ...
user avatar
  • 718
0 votes
1 answer
356 views

Page Refreshing and Resetting Visualforce Parameters

Through a series of events, I have a visualforce component that When a apex:outputLink is clicked calls a component controller method Calls some javascript in the component The javascript calls an ...
user avatar
1 vote
1 answer
945 views

JSENCODE incorrect argument type

I have the following issue: var accountScheduler = "{!JSENCODE(Account.Number_Of_Due_Days__c)}"; Upon initializing the accountScheduler variable I receive the following error: Error: Incorrect ...
user avatar
  • 397
0 votes
1 answer
297 views

ActionFunction call a controller method but "system.debug" messages are not printed

I have a visualforce page with a page component showing a list of object. I need to call a controller method when a user updates an <apex:inputField> in order to print in the log that value. ...
user avatar
  • 149
0 votes
1 answer
68 views

Actionfunction onComplete works abnormally

Please help about the issue. I have onComplete on actionfunction called by button, and called function is another actionfunction that return PageReference for moving to next page. When I click button ...
user avatar
0 votes
1 answer
2k views

Dynamic Rendering of Div based on Apex Controller Value

I would like to reRender a Div based on some logic. Initially the div will be set as display:none as per the logic (Checking whether the variable is null or not). But after passing value to ...
user avatar
  • 1,155
0 votes
1 answer
33 views

Actionfunction doesn't work

I cannot find the reason of this situation. Please help experts. I have several actionfunction and all of them are using for saving value to Controller variables. I this situation, one of them doesn'...
user avatar
0 votes
1 answer
369 views

When immediate="true" values in list does not persist

What i am simply trying here is to add one blank wrapper object in wrapperList on click of add another button. Issue is when i set immediate=true in commandLink or in actionFunction, code adds one ...
user avatar
  • 5,724
0 votes
2 answers
574 views

generic timeout for apex:actionFunction

What I'm trying to do is to call function from apex controller on mu VF page with timeout. For this purpose I've decided to add next code <apex:actionFunction name="searchAuthProducts" action="{!...
user avatar
  • 105
0 votes
0 answers
223 views

ActionFunction not getting called from JS method

So I created a custom lookup to provide a search functionality for a contact insert/edit table. The idea is that the user can "load"an existing contact instead of creating a duplicate in the system. ...
user avatar
0 votes
1 answer
109 views

Compare What User Typed in VF inputText with JavaScript

In the code below, I need to be able to use JS to call renderResults(); in my controller, only if a user clears the field where customerToClearSearchText goes on the VF page. If I remove the ...
user avatar
0 votes
2 answers
480 views

apex:actionFunction redirecting to URL with only the visualforce page on it

I am calling the actionFunction from javascript. I tried having return false; after the call as is suggested on a couple other questions I found but nothing works. I tried specifying the reRender prop ...
user avatar
  • 384
0 votes
1 answer
1k views

Pass parameters by checking some condition to apex controller

I am trying to pass parameters by checking some condition inside the Javascript controller. Here's what i am trying to do:- CreateDiscrepancy: function(component, event, helper) { var ...
user avatar
1 vote
2 answers
608 views

how to get which action function is used?

I have these action functions: <apex:actionFunction name="save" action="{!SaveAccount}" oncomplete="executeSD();" status="sub-status"/> <apex:actionFunction name="executeSD" action="{!...
user avatar
  • 319
1 vote
2 answers
1k views

Action Function Param Not Passing to Controller

EDIT: I needed to put a ReRender, but why? Trying to pass an action function param to the VFP's custom controller. The value is not passing as passedVariableString returns null on the debug. Where am ...
user avatar
  • 1,838
0 votes
1 answer
60 views

Need to retrieve values from database without refreshing the entire page

I have a Visualforce page with picklist and associated fields with it. When the picklist value is no I want the other input field values that we have provided to be saved in the database after ...
user avatar
  • 1,456
-1 votes
2 answers
63 views

actionFunction doesn't work when not using all the parameters

I'm using the actionFunction to call a method to create payments from my visualforce page. The thing that changes is the payment type (sometimes its cash sometimes its check and sometimes both). The ...
user avatar
  • 175
0 votes
2 answers
37 views

How to merge 2 similar apex controller method into 1 for 2 different <apex:actionFunction>

I have 2 different apex:actionFunction, one is for save, the other is for saveAndNew: <apex:form > <apex:actionFunction name="save" action="{!save}" status="sub-status"/> <apex:...
user avatar
  • 319
2 votes
1 answer
1k views

apex:actionFunction not passing the parameters

I am currently trying to call an Apex controller function from an apex:actionFunction, but I can't seem to get the parameters to be passed to the controller function. ActionFunction <apex:...
user avatar
0 votes
1 answer
533 views

Prevent reloading of Page on oncomplete of actionfunction

I have below code where I want to do an action to apex action function and oncomplete of it want to call a javascript function. Unfortunately instead of calling the action the action function in my ...
user avatar
  • 2,900
0 votes
2 answers
122 views

actionFunction & html

Trying to find out how to work with actionFuntion in case of usage html instead of VF. My simple piece of code is listed below. Controller: public class Test { public String variable1 {get; set;}...
user avatar
1 vote
1 answer
2k views

apex:ActionFunction not reRendering or showing status

Not sure what is happening here. I am unable to show the spinner status or reRender the page with updated data. I did see this information about reRendering with conditionals but I am reRendering my ...
user avatar
  • 3,179
2 votes
1 answer
684 views

Help with Drag and Drop between multiple lists and Save button function with Controller class

I´ve searched around but havent been able to find anything yet. Ive created a field in the Account object called "nivel" which means level. The idea is that every account record can have 3 possible ...
user avatar

1
2 3 4 5