Skip to content

Instantly share code, notes, and snippets.

@sankaran1984
Created December 10, 2016 20:36
visualforce - Beyond Basics
global class testcls_1_08122016 {
public List<Opportunity> lsOpp { get; set;}
public void myCustAction() {
lsOpp = [Select
Id, Name, IsClosed
From
Opportunity
Limit 10];
}
@RemoteAction
public static List<Opportunity> getOpportunities() {
return [Select
Id, Name, IsClosed
From
Opportunity
Limit 10];
}
webservice static List<Opportunity> getOpportunities_WS() {
return [Select
Id, Name, IsClosed
From
Opportunity
Limit 10];
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment