Establecer como favoritoHarsh Saini (Pwc India) ha preguntado en #Apex5 feb 2018, 14:00Trigger to insert data from one object to another.My code is not working , can anyone tell me what's the mistake in my code.trigger trigger52 on India__c (after insert) { list<san_francisco__c> con =new list<san_francisco__c>(); for(India__c h : trigger.new){ san_francisco__c s = new san_francisco__c(); s.Name=h.Name; s.Company__c=h.Company__c; s.Mobile__c=h.Mobile__c; s.Email__c=h.Email__c; con.add(s); } insert con;}16 respuestasOrdenarOrdenar por fechaOrdenar por más útilOrdenar por fechaCargar más comentarios...Respuesta aceptadaSitanshu Tripathi (SFDC4STUDENTS)9 feb 2018, 10:57Dear Harsh,I'm telling you only Way from this link.Create Test class from yourself.https://sitanshusfdc.blogspot.in/2018/02/apex-trigger-with-helper-class-and-test.htmlAgregar un comentarioEscribir una respuesta...NegritaCursivaSubrayadoTachadoLista con viñetasLista numeradaAgregar vínculoBloque de códigoInsertar imagenAdjuntar archivosURL de vínculoCancelarGuardar0/9000Responder
Respuesta aceptadaSitanshu Tripathi (SFDC4STUDENTS)9 feb 2018, 10:57Dear Harsh,I'm telling you only Way from this link.Create Test class from yourself.https://sitanshusfdc.blogspot.in/2018/02/apex-trigger-with-helper-class-and-test.html