• Raghvendra Singh 22
  • NEWBIE
  • 55 Points
  • Member since 2017


  • Chatter
    Feed
  • 1
    Best Answers
  • 1
    Likes Received
  • 0
    Likes Given
  • 13
    Questions
  • 17
    Replies
I am getting this error: Challenge Not yet complete... here's what's wrong: 
There was an unexpected error in your org which is preventing this assessment check from completing: System.DmlException: Insert failed. First exception on row 0; first error: CANNOT_EXECUTE_FLOW_TRIGGER, The record couldn’t be saved because it failed to trigger a flow. A flow trigger failed to execute the flow with version ID 30150000000GzkN. Flow error messages: An unhandled fault has occurred in this flow
An unhandled fault has occurred while processing the flow. Please contact your system administrator for more information. Contact your administrator for help.: []

Code is:
public class ContactSearch
{
    public static List<Contact> searchForContacts(String St1, String St2)
    {
        List<Contact> ContctList = [select ID,Name from Contact where LastName = :St1 and MailingPostalCode = :St2];
        return ContctList;
    }
}

Please help!!
Hi Guys ,

i am always facing this error:

Challenge Not yet complete... here's what's wrong: 
Ensure that product2Controller is still working as specified in the earlier challenge. 

here is my code :
public class Product2Extension {
    //public List<Product2Extension.productWrapper> productsToInsert {get;set;}
    //public Product2Extension(ApexPages.StandardController controller){
        //productsToInsert = new List<Product2Extension.productWrapper>();          
        //AddRows();    }
    public List<ProductWrapper> productsToInsert {get;set;}
    public Product2Extension(ApexPages.StandardController controller){
        productsToInsert = new List<ProductWrapper>();
        addRows();
    }
       
    public void AddRows(){
        for ( Integer i=0; i<Constants.DEFAULT_ROWS; i++ ){
            productsToInsert.add( new Product2Extension.productWrapper() );
        }
    }
    public List<ChartHelper.ChartData> GetInventory(){
        return ChartHelper.GetInventory();
    }
    public List<SelectOption> GetFamilyOptions() {
        List<SelectOption> options = new List<SelectOption>{
            new SelectOption(Constants.SELECT_ONE, Constants.SELECT_ONE)
        };
        for (Schema.PicklistEntry ple : Constants.PRODUCT_FAMILY) {
            options.add(new SelectOption(ple.getValue(), ple.getLabel()));
        }
        return options;
    }
public PageReference Save(){
        Savepoint sp = Database.setSavepoint();
        try {
            List<Product2> products = new List<Product2>();
            List<PricebookEntry> entries = new List<PricebookEntry>();
            
            for (ProductWrapper wrp : productsToInsert){
                if(null!=wrp.productRecord && null!=wrp.pricebookEntryRecord){
                    
                    if(null!=wrp.productRecord.Name && null!=wrp.productRecord.Family && constants.SELECT_ONE!=wrp.productRecord.Family
                       && null!=wrp.productRecord.Initial_Inventory__c && null!=wrp.pricebookEntryRecord.UnitPrice){
                        products.add(wrp.productRecord);
                        PricebookEntry entry=wrp.pricebookEntryRecord;
                        entry.IsActive=true;
                        entry.Pricebook2Id=constants.STANDARD_PRICEBOOK_ID;
                        entries.add(entry);   
                    }
                }
            }
            
            insert products;            
            for (integer itr=0; itr<entries.size();itr++){
                entries[itr].Product2Id=products[itr].id;
            }
            insert entries;
            //If successful clear the list and display an informational message
            apexPages.addMessage(new ApexPages.message(ApexPages.Severity.INFO,productsToInsert.size()+' Inserted'));
            productsToInsert.clear();   //Do not remove
            addRows();  //Do not remove
        } catch (Exception e){
            Database.rollback(sp);
            apexPages.addMessage(new ApexPages.message(ApexPages.Severity.ERROR,constants.ERROR_MESSAGE));
        }
        return null;
    }        
    public class ProductWrapper{
        public product2 productRecord {get;set;}
        public pricebookEntry pricebookEntryRecord{get;set;}
        public productWrapper(){
            productRecord = new product2(Initial_Inventory__c =0);
            pricebookEntryRecord = new pricebookEntry(Unitprice=0.0);
        }
    }
}

Thanks,
Raghvendra
Hi Guys,

I did every step carefully. i dont know why test coverage is very low
Can anyone help me

ThanksUser-added image
Hi Guys,

How can we show lightning component in List View ?
is there any way ?

Thanks,.
Raghvendra
Hi Guys,

How to achive this:  Fetch the Email template and show in dropdown in Lightning Component

Thanks,
Raghu
Hi All,
Can anyone guide me regarding developer certification PD1., How to prepare for it.

Thanks
Hi All,

I want to validate phone number in E.164 format?
Please help me
 
Hi All,

how to achieve Visualforce email template with multiple language.

Thanks,
Raghu
Hi All,
I have 6 objects which have a common field(Business Unit field). Now i need to take backup of all triggers, workflows,classes etc which are related to these objects and this field... i am trying to do in eclipse. Do you have any idea how to do it.
I have more object in my org but i need to take backup only 6 object and on the basis of its field.... Plz help me 

Thank you all
Hi All,
I have 6 objects which have a common field(Business Unit field). Now i need to take backup of all triggers, workflows,classes etc which are related to these objects and this field... i am trying to do in eclipse. Do you have any idea how to do it?

Thanks,
Raghvendra Singh
 
Hi ,
Unable to read repository at http://media.developerforce.com/force.ide/eclipse42/content.xml.
Socket operation on nonsocket: configureBlocking i am getting this whenever i m=am trying to connect force.com with eclipse.
anyone plz help me

Thanks,
Raghu
Hi All,

plz could anyone help me to pass this challenge

Thanks
Hi,
Picklist value is not showing whenever i insert through data loader,Please anyone can help me
#dataManagement
#dataloader
Thanks
Hi Guys,

How to achive this:  Fetch the Email template and show in dropdown in Lightning Component

Thanks,
Raghu
I am getting this error: Challenge Not yet complete... here's what's wrong: 
There was an unexpected error in your org which is preventing this assessment check from completing: System.DmlException: Insert failed. First exception on row 0; first error: CANNOT_EXECUTE_FLOW_TRIGGER, The record couldn’t be saved because it failed to trigger a flow. A flow trigger failed to execute the flow with version ID 30150000000GzkN. Flow error messages: An unhandled fault has occurred in this flow
An unhandled fault has occurred while processing the flow. Please contact your system administrator for more information. Contact your administrator for help.: []

Code is:
public class ContactSearch
{
    public static List<Contact> searchForContacts(String St1, String St2)
    {
        List<Contact> ContctList = [select ID,Name from Contact where LastName = :St1 and MailingPostalCode = :St2];
        return ContctList;
    }
}

Please help!!
I've turned on the functionality in my profile and linked it to my Trailhead account, yet no badges are showing.  Please advise?
User-added image
User-added image
Hi,

I have 31 trailhead Badges:
User-added image

But in partners account, it is showing 0:
User-added image

Can anyone please tell where to check for this issue?

Regards,
Dheer
Hi, 

   I want to develop salesforce code in my local eclipse environment. I follwed steps mentioned here :
    https://developer.salesforce.com/page/Force.com_IDE
So my eclipse is ready now but I dont know how to import code(apex classes, components, visual force pages) from my sandbox into my local enviornment and how I can again deply changes to salesforce cloud.

Can anyone please help me to solve this issue.


Thanks,
Abhishek
  

Is there a way to perform a "global search" through all Apex code --- classes, triggers, etc.?  For example, if I want to search for a specific block of code but don't remember what class it's in...

  • April 30, 2010
  • Like
  • 0