-
Error in Salesforce Ligthning component
Hi all,
trying to build a lightning component but flashing this error
This page has an error. You might just need to refresh it.
Assertion Failed!: Unknown controller action 'clickCreateCampingList' : undefined
Failing descriptor: {ui$button$controller$press}CONTROLLER
({
clickCreateCampingList: function(component, event, helper) {// Simplistic error checking
var validCampinglist = true;// Name must not be blank
var nameField = component.find("expname");
var expname = nameField.get("v.value");
if ($A.util.isEmpty(expname)){
validExpense = false;
nameField.set("v.errors", [{message:" name can't be blank."}]);
}
else {
nameField.set("v.errors", null);
}// ... hint: more error checking here ...
// If we pass error checking, do some real work
if(validCampinglist){
// Create the new camping list
var newitem = component.get("v.newitem");
console.log("Create campingList: " + JSON.stringify(newitem));
helper.createCampinglist(component, newitem);
}
}
})
Log In to reply.
Popular Salesforce Blogs

How Are Salesforce Managed Services Beneficial For The Businesses?
Salesforce is a well-renowned name in the CRM industry that provides a 360-degree view of the users to all the departments that enable businesses to…

Wrapper Classes in Salesforce | Here's What You Need to Know
Apex Wrapper Classes are custom classes in Salesforce that are used to hold one or more primitive data types as members. This allows for encapsulating…

How to Integrate HubSpot With Salesforce CRM: Three Options
The goal of every business is to drive sales. However, its success is determined by the synergy of all departments, especially marketing and sales. 52.2%…
Popular Salesforce Videos
Improve Your Front and Backend Team Collaboration With Sinergify | Salesforce CRM
Businesses that use Salesforce CRM and Atlassian Jira separately face a lack of team collaboration, inconsistent customer data, slower case resolution, and reduced agent productivity.…
How To Use Journey Builder In Salesforce Marketing Cloud | Salesforce Tutorial
How to use Journey Builder in Marketing Cloud. This video will cover the following points - 1. Introduction Get a brief introduction to Journey Builder…
What is Apex? | Way to become a Salesforce Developer | Salesforce Development Tutorials
This video will provide you a complete path to become a Salesforce Developer. It includes very important and beneficial topics like Apex, Visualforce, Lightning. …