Most Popular
1500 questions
13
votes
4 answers
why we use {get; set;} syntax in wrapper class or in controller class
public class Wrapper
{
public String fname{get; set;} //why we use get; set; syntax here
public String lname{get; set;}
public String uname{get; set;}
}
also here
public class Controller{
public List WrapperList {get;set;}
…
Saroj Dhabale
- 131
- 1
- 1
- 4
13
votes
3 answers
Batch @future calls?
Im trying to build what seemed like a simple SMS messaging application using Twilio's api and running into a few strange momments.
So I have an SMS object that stores the messages and i wrote a simple trigger on there to actually call the code that…
Keith Mancuso
- 3,701
- 7
- 36
- 66
13
votes
4 answers
How to pass more than one parameter for Invocable Methods and collect the return value?
@InvocableMethod annotation is not allowing to pass two parameters. I want to invoke a method through process builder which is having :
Input type : Date, Date
Output type : Integer
Is there any way to achieve this requirement?
Stuart Cole
- 395
- 2
- 4
- 10
13
votes
2 answers
Force.com IDE in brand new eclipse fails to Add/Remove Metadata Components (on specific Orgs)
OUTLINE
When I want to select the Metadata types for the project, I only get the error:
Unable to open custom component selection dialog. Reason: An
unexpected error has occurred.
I don't know if it matters, but I have multiple JDKs and JREs…
Uwe Heim
- 28,350
- 18
- 115
- 283
13
votes
1 answer
Massive Spring '17 bug: SOQL returns wrong Custom Metadata Type picklist value
Based on all evidence gathered there is a major bug in Spring '17 involving Custom Metadata Types and picklist values: what SOQL returns is different than what's saved in the database.
To reenact:
go to a sandbox org (where Spring '17 has been…
Mossi
- 3,956
- 3
- 34
- 61
13
votes
3 answers
Showing a loading Spinner for my component but not during Init
Ok,
So I am trying to implement a Spinner whenever my component is doing something server side. It is working just fine EXCEPT:
When the Lightning component is in the Lightning Page it seems the waiting and done waiting event is called like 20…
Eric
- 54,152
- 11
- 100
- 195
13
votes
1 answer
Moment JS format returns function string in Lightning Spring 17
I use momentjs's library in my lightning application to manipulate javascript dates.
When my sandbox was updated from winter 17 to spring 17 I noticed the format function doesn't work any more.
Instead of returning a string with the correct format,…
Jovabe
- 737
- 2
- 5
- 18
13
votes
5 answers
Lightning Components: can aura:id be set to an component attribute?
I know it was never possible in Visualforce, but I wonder if it might be possible now in Lightning Components to have an aura:id not hardcoded but bound on an element like:
Uwe Heim
- 28,350
- 18
- 115
- 283
13
votes
1 answer
Query Which Profiles Have Read Access To Specific Object?
Since I couldn't think of how to write this query off the top of my head, I thought it might be worth sharing. How can I query which Profiles have Read permission on a specific object? I knew it would have something to do with ObjectPermissions and…
Adrian Larson
- 149,971
- 38
- 239
- 420
13
votes
4 answers
Why is migrating changes between multiple orgs such a pain
So I've developed a couple of Salesforce / Force.com projects but the one thing I really hate is migrating changes between orgs. Maybe I'm doing it wrong, or I'm missing tools but something just snapped today.
I'm working on a fairly easy Salesforce…
Daniël Zwijnenburg
- 243
- 2
- 7
13
votes
3 answers
Lightning component's .focus() not working
I have an input field:
With controller code:
var input = cmp.find("name-input");
console.log(input);
input.focus();
This gives the error:
Access Check Failed! Component.method():'markup://ui:focus' is not…
nicstella
- 589
- 1
- 7
- 19
13
votes
1 answer
What is the Maximum Type Depth?
I saw this question posted as an answer, but no one seems to have asked it since.
What is the maximum number of levels classes can inherit?
In other words, what are the maximum N and M such that the following will still compile?
public virtual…
Adrian Larson
- 149,971
- 38
- 239
- 420
13
votes
2 answers
Is there a way to loop through enums?
For an APEX class with:
public class EuchreCard{
public enum suite {CLUBS, DIAMONDS, HEARTS, SPADES}
public enum rank {NINE, TEN, JACK, QUEEN, KING, ACE}
}
Is there a way to loop through all enum values? For instance, I want to create a…
Scott Pelak
- 7,514
- 2
- 39
- 72
13
votes
1 answer
Calling addFields in Extension class works on page, fails in test class
I've got a class which acts as a controller extension. The class is designed to add a number of fields to the StandardController so a component used on the page can dynamically access some fields.
However, when I went to test the class, I…
battery.cord
- 8,825
- 8
- 31
- 59
13
votes
3 answers
How to convert a Visualforce apex:pageMessages to be lightning style
During my working on converting existing pages to be lightning experience style (as known as slds style). One of the challenges I have faced is to convert . Usually the controller side of code is something like below:
public…
Lance Shi
- 12,989
- 14
- 78
- 178