• Tammy Hansford
  • NEWBIE
  • 0 Points
  • Member since 2021

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 6
    Replies
Hi Everyone,
I am getting issue while doing this LWC challenge - 
Use Lightning Data Service to Work with Data

ErrorWe can’t find an event handler named 'handleSuccess'.

Code -
contactCreator.Js
import { LightningElement,api,track } from 'lwc';
import { ShowToastEvent } from 'lightning/platformShowToastEvent';
//import CONTACT_OBJECT from '@salesforce/schema/Contact';
//import FIRSTNAME_FIELD from '@salesforce/schema/Contact.FirstName';
//import LASTNAME_FIELD from '@salesforce/schema/Contact.LastName';
//import EMAIL_FIELD from '@salesforce/schema/Contact.Email';


export default class ContactCreator extends LightningElement {
    @api recordId;
    @api objectApiName;
    @track fields = ['FirstName', 'LastName', 'Email'];

    handleSuccess(event){
        
        const toastEvent = new ShowToastEvent({
            title: "Contact created",
            message: "Record ID: " + event.detail.id,
            variant: "success"
        });
        this.dispatchEvent(toastEvent);
    }

}
contactCreator.html
<template>
    <lightning-card>
        <lightning-record-form
            object-api-name={objectApiName}
            fields={fields}
            record-id={recordId} 
            onsuccess={handleSuccess}>
        </lightning-record-form>
    </lightning-card>
</template>

Please help me what i am doing wrong here as i have declared handleSuccess event in the JS .

Thanks,
I don't know much CSS but want to learn slds. In trailhead, it seems to be difficullt to learn slds. Please tell me a way to learn SLDS from basics.
Hi,
What is the  best resource to learn LWC? I have gone through most LWC modules - but still feel like I need more depth. 

So, short of reading the LWC developer guide, .. any links? suggestions? 

I am new to HTML/CSS/Javascript etc
Hello everyone, please tell me if I can learn Apex without knowing other programming languages. I understand that Apex is a shorter version of Java. But since Java is not advised for learning to beginners, as the first programming language, so I ask this question about Apex
So, is it possible to learn Apex and Visualforce from scratch, without any technical knowledge nor formation in informatics/programming?
Hello all,

While preparing for the sales cloud certificate, I came across a question which seems debatable to me. I find in the documentation of work.com that A is possible. However, C and D seem to be also true (although the correct way to phase D would be to skip the word "coaching"). Can you please help and tell me which options are true and why?

How can you use Work.com to increase the productivity of your sales reps?(Choose 2 answers) 
A. Feedback can be requested for the entire sales team
B. Coaching statistics can be linked to reports
C. Feedback can be given publicly or privately
D. Coaching goals can be linked to reports

In particular, I can't get this program to respond with any debug logs: https://gist.github.com/dradtke/7602458. It's a small Java program that logs in, executes some anonymous apex, and prints out the results. It works fine if the code fails to compile or runs into an error, because those values are pulled directly from the ExecuteAnonymousResult, but I can't get it to respond with any information when it succeeds. I used the tip listed here to try and pull the debug info, but conn.getDebuggingInfo() always returns null.

 

Any tips on what might be going wrong?