Skip to main content

Questions tagged [javascript-remoting]

JavaScript remoting in Visualforce allows you to call methods in Apex controllers from JavaScript.

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

Avoiding Batching of Concurrent Remoting Calls with LCC.callApex in Salesforce

I am developing a managed package in Salesforce where I have integrated Angular as a static resource. From the Angular application, I make remoting calls to Apex methods using LCC.callApex. However, ...
Arkan Mansuri's user avatar
0 votes
0 answers
61 views

Exposing existing methods via the REST API

Given a class with a large number of methods (200+) because it acts as a fascade for the putrposes of Visualforce remoting, how would these same methods be best exposed to the REST API? I'm thinking ...
Matt Lacey's user avatar
  • 25.7k
-1 votes
1 answer
267 views

How to get information about user in head markup of community

Experience Builder--> Settings-->Advance-->Head Markup I tested already things like <script src="../../soap/ajax/33.0/connection.js"></script> <script> var ...
Alex's user avatar
  • 1
1 vote
0 answers
185 views

Uncaught TypeError: Cannot read properties of undefined (reading 'tid')

Recently I noticed our salesforce instance spitting the following into the console on user login Uncaught TypeError: Cannot read properties of undefined (reading 'tid') No changes have been made in ...
fom's user avatar
  • 11
0 votes
0 answers
538 views

Success Message with Toast events not working

Js code import { LightningElement, api, track } from 'lwc'; import { NavigationMixin } from 'lightning/navigation'; import {FlowNavigationNextEvent, FlowAttributeChangeEvent} from "lightning/...
Noha's user avatar
  • 13
3 votes
1 answer
1k views

Visualforce.Remoting returns "Remoting request authorization expired. Refresh the page and try again"

I have an issue with Visualforce Remoting. The issue presents it self, when my visualforce page executes a remote call to the related custom apex controller. I can see the browser console log the ...
Andreas86's user avatar
  • 357
1 vote
1 answer
424 views

How to pass JS Remoting Apex response to a React component hosted in VF?

I'm working in a simple POC to learn how to connect React-Visualforce-Apex. I have success inserting data generated in a React form to Salesforce, but now I would like to retrieve Salesforce data on ...
Alex Cortes's user avatar
1 vote
1 answer
61 views

Getting some Javascript remoting errors specifically in a managed package

Apex: global with sharing class SomeClass { @RemoteAction @AuraEnabled(Cacheable=true) global static Id someMethod() { return u.Id; } } VF: <apex:page controller="SomeClass"&...
user105636's user avatar
2 votes
0 answers
45 views

Check if Visualforce page uses JavaScript Remoting ? JS proxies were not generated for the controller cannot use public remoted methods in Iframe? [duplicate]

I have several Visualforce pages from managed package (some of them use JavaScript Remoting , some not). And I need to show one of them (depending on the parameter) on my LWC using iFrame. The problem ...
Vitalii Dehnerys's user avatar
0 votes
0 answers
91 views

RemoteAction Not Working with Standard Controller

I'm attempting to pass some JavaScript variables to an apex controller. I am using JavaScript Remoting, but I'm seeing an 'OpportunityStandardController.RemoteAction' error when I attempt to deploy. ...
user82573's user avatar
1 vote
1 answer
1k views

how to convert &#39 ; to single quote in apex

Abc&#39;s Place this coming in apex. actual picklist value is => Abc's Place, Abc&#39;s Place is coming from json from Vf page to Javascript Remoting. It's throwing an error when I am ...
Umesh Beti's user avatar
-1 votes
1 answer
316 views

Javascript Remoting salesforce unknown property remote action

My VisualForce page: <apex:page docType="html-5.0" controller="JavascriptRemotingController" showHeader="false"> <head> </head> <body id="bd&...
Zan3's user avatar
  • 39
0 votes
1 answer
154 views

Cannot retrieve the property value in JavaScript from Apex controller after making the call to the web service

I'm trying to retrieve the boolean value for the property from my controller. This value is being assigned after the call to the web service like this: public Static Boolean myVariable { get; set; } @...
heisenberg's user avatar
0 votes
1 answer
68 views

JS Remoting cannot access contacts

I've read all the documentation I could find, and tried several variations of code, but nothing has produced results. I'm working on a pre-chat form for Live Chat, and what I want to do is search all ...
Justin Szczurowski's user avatar
4 votes
2 answers
1k views

Tightening security around Javascript Remoting from Visualforce

We have a community portal built off of Visualforce pages and on those pages we do a lot of Javascript Remoting. Due to the complexity of our org, most of the Apex classes holding these remote methods ...
Ryan Werner's user avatar
1 vote
1 answer
497 views

Why Do @RemoteAction Annotated Controller Methods Return Data that Non-Annotated Controller Methods Do Not?

The only documented difference that I can find between the @RemoteAction Annotation and Non-Annotated apex methods is this section from the Apex Developer Guide (https://developer.salesforce.com/docs/...
Morgan Marchese's user avatar
0 votes
2 answers
985 views

JSON deserialize is coming null When I'm testing

I just Tested this code, When I'm running this JSON not assigning to the variables it is coming NUll. String requestString='{"terms":{"customerCode":"sadasd","customerName":"sadasd","incoterm":"EXW","...
VINOD's user avatar
  • 3
2 votes
0 answers
170 views

Can I CRUD Managed Package Objects via Lightning or VisualForce with a non-licensed user (Customer Community User)?

First and foremost, we are not trying to be unethical. I am in the middle of vetting Salesforce CPQ+ and Salesforce Billing as potential replacements for our existing quoting and billing systems. ...
Morgan Marchese's user avatar
1 vote
1 answer
153 views

Is there a way to define the sforce.Sobject's field using a javascript variable? (ajax toolkit in visualforce)

As shown in the code comments below I want to use the variable "someCustomField" in the account.someCustomField statement but the error message tells me "someCustomField" doesnt exist despite its ...
Peter Noges's user avatar
  • 1,140
0 votes
1 answer
157 views

Is it possible to access JavaScript Remoting methods from outside of Salesforce?

I have a number of pages that use JavaScript remoting methods in order to access controller methods. I would like to run some automated tests on these methods and wonder if it's possible to access ...
lemming's user avatar
  • 483
2 votes
1 answer
387 views

Does marking Javascript Remoting "buffer: false" really make it async?

Lets say I have 5 VF pages in a flexipage, each VF page has Javascript remoting which queries on different objects. Javascript remoting is marked as buffer: false. Now as we know Apex is single ...
Nagendra Singh's user avatar
2 votes
1 answer
169 views

Promises not being awaited when resolved in remoteAction callback

I'm trying to upload an array of files to an s3 bucket. I'm building an array of promises for each file, that generates the pre-signed URL, blobs the file and then does the upload. Each promise should ...
Callum Evans's user avatar
0 votes
1 answer
72 views

Search while Type functionality on VFP not working as expected between apex:tab transition

I have 2 apex:tabs (Primary Tab, Secondary Tab) in visualforce page which shows a table of accounts list. I have a custom script for "search-while typing" functionality with below script. //VFP <...
SMorse's user avatar
  • 39
1 vote
0 answers
89 views

salesforce javascript remoting and offline support in hybrid mobile app(local or remote) based on salesforce mobile sdk

I have a mobile local hybrid app built upon salesforce mobile sdk. We have offline support in our application and using REST API calls get the salesforce data. But now we want to leverage the ...
Manjeet Sharma's user avatar
1 vote
0 answers
48 views

Prototype Pollution using Visualforce Remote Action

I'd like to know if anyone has faced issues with javascript arrays when declaring Remote Action, have you? How have you overcome it? Asking because the following code started to fail on key remove (...
Jeferson Chaves's user avatar
0 votes
1 answer
317 views

Dynamic lightning:inputfield validation not working

I am trying to set a validation on a dynamic lightning:inputfield bus this is not working neighter do I get an error. I think my binding isn't correct. Component <aura:iteration items="{!v....
Thomas's user avatar
  • 2,310
2 votes
2 answers
12k views

Lightning Controller window.open();

When I use window.open(); in my lightning controller, it opens the URL but at the end of the salesforce's url. It does open in a new tab which is what I want but the url is confusing me. For example, ...
Olivia's user avatar
  • 3,471
1 vote
1 answer
166 views

Unable to use variable of javascript remote method variable in chart.js code. It is coming as undefined

I have to use list of accounts as labels in my chart. In order to fetch list of records I have used js remoting. I am able to fetch but not use within chart.js labels. Here goes my vfp :- <...
Mayank Parnami's user avatar
0 votes
2 answers
70 views

Delete button is disabled due to time out issue

I have a page where websites are built by the users. When an user tries to delete the site from the page, the page is throwing error stating there is some issue and the delete button is disabled ...
Sastri's user avatar
  • 141
0 votes
1 answer
499 views

How to refresh a standard page using remote action in vf page?

I need to trigger a controller action once user loading the standard account page. So that I have created a custom vf page with zero height and embedded it in the account page layout in order to call ...
Prasad Ruwanpathirana's user avatar
1 vote
2 answers
2k views

Error using visualForce Remoting for javascript call to custom apex controller RemoteAction

I am trying to call a custom apex controller from javascript code in my visual force page but keep getting the following error : Visualforce Remoting Exception: No such column '_name' on sobject of ...
David Geismar's user avatar
1 vote
1 answer
649 views

Pass the callback value (result) from Visualforce.remoting.Manager.invokeAction to apex:repeat value.

I want to pass the return value of my remote action method to apex controller from javascript. This is my code. Visualforce.remoting.Manager.invokeAction(//get store list for map points ...
boy george's user avatar
0 votes
0 answers
448 views

How to create a map in JavaScript in VisualForce page

I am trying to create a map in VisualForce page where I also need to pass the inputtext value dynamically. Also once the calling the apex method defined as @RemoteAction will return back SObject[ ] so ...
Sharma_raj's user avatar
0 votes
1 answer
899 views

Pass Map<String, List<String>> from apex to javascript

I want to pass a Map<String, List<String>> from apex controller to javascript. Here is my approach, I am using javascript remoting for it but it's not working. controller function @...
Abhishek Prakash's user avatar
4 votes
1 answer
1k views

Call an apex method when leaving a Visualforce page

I have done some looking around and I cannot seem to find a current solution to my issue. I would like to call an apex method to remove records when a user leaves a visualforce page. I've gone down ...
JRiffe's user avatar
  • 1,673
4 votes
2 answers
1k views

How can I stop JavaScript remoting reloading page

I'm trying to see what is my RemoteAction result however the page reloads before it happens. How can I stop this? VF Page: <button class="btn-enter-panel" onclick="getRemoteName()">enter <...
M. Massula's user avatar
0 votes
2 answers
758 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="{!...
neckobik's user avatar
  • 105
0 votes
1 answer
92 views

Salesforce Http response getting changed

There is a situation where I am sending a Http Request to my server. The result my server sends is [{"Data1":"MyData"}] but the data I am getting on salesforce side from response.getBody() is : [{"...
raunakchoraria's user avatar
0 votes
1 answer
316 views

Can we access Apex Controller class from a separate .js file?

I have a separate .js file and I want to access controller properties and functions using that file but as far as I know we must have a .vfp page and a controller attribute is given to apex:page, but ...
raunakchoraria's user avatar
2 votes
1 answer
355 views

Pass enum value in remoting method

I'm calling a remoting method from javascript. The method expects a custom class with one of the fields of type ConnectApi.MarkupType. While sending a string value for this field, I'm getting an ...
vishesh's user avatar
  • 763
1 vote
2 answers
527 views

Unknown method error in visual force remoting while passing the parameters

When i am trying to send parameter from Visul force remoting to apex method, it is saying that Unknown Method but method was exists in controller . Can anyone please help me how to fix this issue. VF ...
Prince's user avatar
  • 11
0 votes
1 answer
201 views

Send data from apex page to another apex page using javascript remoting

I have an apex page where I display a table with some information retrieved from an API, now I want to send information from the table when an user clicks a row from it, redirect to another apex page, ...
Manu's user avatar
  • 43
3 votes
2 answers
3k views

Upload large ContentVersion records

I'm using a @RemoteAction to upload files to Salesforce, saving them as ContentVersion (Chatter files). I'm uploading the base64 Blob of the file. This works great for small (<1MB) files. I am NOT ...
AvailableName's user avatar
0 votes
3 answers
930 views

Can I declare more than one RemoteAction function in my class?

I have a class where I have declared @RemoteAction functions to work using Javascript Remoting. When I only had one function everything was working fine, but when I created a second @RemoteAction ...
Manu's user avatar
  • 43
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 ...
Olivia's user avatar
  • 3,471
0 votes
2 answers
399 views

Apex.Message in Iframe

What am I doing wrong? I hope this is just a simple mistake and me writing it out will even help spur some thought. I have a VFP embedded in a related list on the Lead object. When a user clicks a ...
Olivia's user avatar
  • 3,471
1 vote
0 answers
198 views

How to prevent VF Remoting from failing when there's no Referer header in the request?

I'm working on a ReactJS app served through a VisualForce page. If the initial request to the page containing the app doesn't include an HTTP Referer header, none of the requests sent to the page's ...
Glen Aultman-Bettridge's user avatar
-3 votes
1 answer
357 views

Submitting an Account Record into an approval when the Account Rating on warm Approved send an email automatically

Apex Class:- global class SAPRequest{ WebService static void SendApprovalRequest(string id) { // create the new approval request to submit Approval.ProcessSubmitRequest req = new Approval....
bingi kumarcrm's user avatar
0 votes
0 answers
245 views

Javascript button click on Apex Page

I have a requirement to develop such that a click on a Javascript button will send an email to a particular email address. After that it will open a new window. On it "Email Sent" will show and then ...
Testing_SFDC's user avatar
  • 2,950
0 votes
1 answer
447 views

insertion of a date field from vf page

I have a requirement to insert a date field for opportunity on vf page.For the creation of record i used vf remoting.But when i am sending opportunity closed date from page to controller and trying to ...
Gaurav singh's user avatar

1
2 3 4 5
8