• Rizwan Ali 12
  • NEWBIE
  • 10 Points
  • Member since 2019

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 1
    Questions
  • 4
    Replies
Hi,
Criteria:
On create Opportunity record , the Job Object records will create with according to Opportunity 'Quntity' Field ex: if quntity is 5 then create 5 job records and opportunity 'Amount' set in Job Object divided by 5 ex: If quntity is 5 and Amount is 1000 , set 200 to each Job records
I did this but didn't work
Please answer it.
Thanks in Advance.
If(Trigger.IsAfter && Trigger.isInsert)
   {
       for(Opportunity opp : Trigger.New)
       {
           Decimal Amount = opp.Amount / opp.TotalOpportunityQuantity;
           
           List<job__c> listofjob = new List<job__c>();
           
           for(integer i = 1; i<=opp.TotalOpportunityQuantity; i++)
           {
               job__c ajob = new job__c(Name = 'Job'+i, Amount__c =Amount );
               listofjob.add(ajob);
           }
           
           if(listofjob.size()>0)
           {
               insert listofjob;
           }
       }
   }

 
Hi,
Criteria:
On create Opportunity record , the Job Object records will create with according to Opportunity 'Quntity' Field ex: if quntity is 5 then create 5 job records and opportunity 'Amount' set in Job Object divided by 5 ex: If quntity is 5 and Amount is 1000 , set 200 to each Job records
I did this but didn't work
Please answer it.
Thanks in Advance.
If(Trigger.IsAfter && Trigger.isInsert)
   {
       for(Opportunity opp : Trigger.New)
       {
           Decimal Amount = opp.Amount / opp.TotalOpportunityQuantity;
           
           List<job__c> listofjob = new List<job__c>();
           
           for(integer i = 1; i<=opp.TotalOpportunityQuantity; i++)
           {
               job__c ajob = new job__c(Name = 'Job'+i, Amount__c =Amount );
               listofjob.add(ajob);
           }
           
           if(listofjob.size()>0)
           {
               insert listofjob;
           }
       }
   }

 
I am not able to get the challenge to work on this module. Anyone else figure it out. It appears to completely ignore the changes or cant find the app. Message is: "Challenge Not yet complete... here's what's wrong: Could not find the 'Salesforce1 for Android' Connected App with the specified settings."

Checked it a dozen times, but no luck. It looks like perhaps the app name no longer has exactly the same name.