• harsha B R 9
  • NEWBIE
  • 50 Points
  • Member since 2014

  • Chatter
    Feed
  • 0
    Best Answers
  • 1
    Likes Received
  • 0
    Likes Given
  • 21
    Questions
  • 18
    Replies
Hi,

Salesforce standard error messages is displaying differently for required fields.

Standard objects fields marked as required is display the error message in the below format.
User-added image
Custom objects fields marked as required is dispalying the below error message.
User-added image


Please let me know why there is discrepancy and how to make it unique across the sandbox.

Thanks & Regards,
Harsha BR
Hi Everyone,

Requirement is to override the complete standard detail page (in Lightning) including related lists with the custom lightning component.

What are the considerations for replacing the standard detail page with the custom lightning component?

Thanks & Regards,
Harsha BR
Hi,

Business requirement :-
"Edit" standard button on the Junction object should take to the edit page of the master record insted of Junction object record.

How to achieve the above functionality?

Thanks & Regards,
Harsha BR
Requirement on Cases List View.

Case has a city custom field which can contain values like Bangalore,Mumbai,Chennai etc. User can see only the cases that belong to his city.

For Example,if User belong to Bangalore location login,he can only see cases whose city field value is Bangalore and he should not see any cases whose city value is other than Bangalore.
Any help would be greatly appreciated.
How to add "undo" link in the custom toast message after deleting a record in lightning salesforce?
Hello Everyone,

The requirement is to pull the data from the Core banking system to Salesforce. Core banking system supports SOAP API.

Challenge is  core banking system allows only supports internal office network to access the data.

What would be the best possible integration approach to pull the data to Salesforce?

PS: End Users access salesforce from outside of office location too.

Thanks & Regards,
Harsha BR
Hi ,

I have embedded a Report on a VF page and added the VF page in the Record detail page of a object.
I have used analytics:reportChart tag and dynamically filtering the reports based on the Record ID. It is working as expected.

But, when a user clicks the report name or Refresh Date like "As of Yesterday 4:45 PM", the report is breaking and an instance of Salesforce is opening inside the report.

Please suggest a workaround which disables the click event on Report chart name.

Any help is highly appreciated.

Thanks & Regards,
Harsha BR
 
Hello,

I am using the basic username and password authentication mechanism for integration.

Which is the endpoint URL that needs to set as endpointurl to get the access token and inturn data?

Please check the below code and suggest if any changes are required.

public class AccessToken {
    
    
       private Static final String username = 'test@test.com';
       private static final String password = 'XXXsecuritytoken';
    
      public class deserializeResponse
       {
         public String id;
          public String access_token;
       }
    
   public static void ReturnAccessToken ()
   {
        String reqbody = 'grant_type=password&username='+username+'&password='+password;
         Http h = new Http();
          HttpRequest req = new HttpRequest();
          req.setBody(reqbody);
          req.setMethod('GET');
        req.setEndpoint('https://test.salesforce.com/services/oauth2/token');
          HttpResponse res = h.send(req);
        system.debug('*** Response Body***'+res.getbody() );
         deserializeResponse resp1 = (deserializeResponse)JSON.deserialize(res.getbody(),deserializeResponse.class);
         system.debug('@@@@access_token@@'+resp1 );
          //return resp1.access_token;
   }
}

Any help is much appreciated.

Thanks & Regards,
Harsha BR
 
Hello Everyone,

Salesforce displays the standard message of "No Records to display" if records are not available for the object in the Related list of the Master detail page.

Can we customize the standard salesforce message to "No Records to display today".

Please let me know if this can be achieved.

Thanks & Regards,
Harsha BR
Hi,

The requirement is to pull data from PDF and storing it as the custom field on Account object?

Is it possible to parse the PDF using Apex? 

If Yes, please share the necessary documents.

If No, please share the alternative approach/solution.

Any help would be highly appreciated.

Thanks & Regards,
Harsha BR
Hi Everyone,

How to enable live agent to 1000 users who belong to a single profile?I need to do this in the production org.

Any help is appreciated.

Thanks & Regards,
Harsha BR
Hello,

We have built Live Agent for one of our client.We want to customise the chat end messgaes.

Eg:- If the visitor ends the chat,Message will be "Chat ended by Visitor".Asssuming visitor name as Bob,we want to customise as "Chat needed by Bob"

Eg:- If the Agent ends the chat,Message will be "Chat ended by Agent".Asssuming Agent name as Maria,we want to customise as "Chat needed by Maria"
Is it possible with standard live agent functionality? If No,what is the alternative approach to achieve the requirement?


Thanks & Regards,
Harsha BR
Hello,

i have made only 5 tabs as Default on.All other tabs have been made as Tab hidden.

Haing said that,all the 5 tabs are visible.Apart from that + button is also visible.My client does not need + button after the 5 tabs.

Is there any way I can hide the + button in Salesforce classic.

Any help is highly appreciated.

Thanks & Regards,
Harsha BR

Thanks & Regards,
Harsha BR
Hello All,

I am unable to find the Reset my Security token option in salesforce Lightning.
However,I am able to find it in Classic. My settings --> Personal --> Reset My Security Token

Please let me know where I can reset my security token in salesforce lightning.
Hello Everyone,

Is there any way to find out the currently logged in users of the org.

Requirement :- When a lead is created,I need to assign the lead dynamically to only to the logged in users(Need to fetch all the logged in users of the org programatically).

Salesforce has mentioned in one of the ideas that they have implemented it - https://success.salesforce.com/ideaView?id=08730000000BpPOAA0

Executed the SOQL query - Select a.UsersId, a.IsCurrent, a.UserType, a.SourceIp, a.SessionType, a.SessionSecurityLevel, a.ParentId, a.NumSecondsValid, a.LoginType, a.LastModifiedDate, a.Id, a.CreatedDate From AuthSession a

But,it returned only my user record.It didn't not returned the other users who have logged in the orge.

All the logged in users can be accesed at the UI level --> security controls --> session Management.

Any idea/help is appreicated.

Thanks & Regards,
Harsha BR 
Hello Everyone,

Facing the below error in test class.

System.DmlException: Insert failed. First exception on row 0; first error: FIELD_INTEGRITY_EXCEPTION, field integrity exception: unknown (pricebook entry is in a different pricebook than the one assigned to the opportunity): [unknown]

Following is the piece of code:-
 public static testmethod void updateAccumulatedPriceTest()
    {
        Date closedDate=System.today()+1;
        Id accRecordTypeId =[SELECT id from RecordType where Name ='Partner VIP'].Id;
        
        //Creating Price book records
        List<Pricebook2> lstPriceBooks=new List<Pricebook2>();
        Pricebook2 objPriceBook=new Pricebook2(Name='VirtualCare',IsActive=true);
        lstPriceBooks.add(objPriceBook);
        insert lstPriceBooks;
        
        //Fetching system standard price book
        Pricebook2 standardPB = [select id from Pricebook2 where isStandard=true];
        
        //Creating an Account records
        List<account> lstAccs=new List<account>();
        Account objAcc=new Account(Name='Test Account',Envios_Automaticos__c=false,Tarifa_Acumulado__c=objPriceBook.Id,
                                   Contact_email__c='dummy@email11.com',RecordTypeId=accRecordTypeId);
        lstAccs.add(objAcc);
        insert lstAccs;
        
        
        //Creating Product records
        List<Product2> lstProducts=new List<Product2>();
        Product2 objProd=new Product2(Name='Product',isActive=true);
        lstProducts.add(objProd);
        insert lstProducts;
        
        

        //Creating the list the opportunities
       List<Opportunity> lstOpps=new List<Opportunity>();
        Id oppRecordTypeId =[SELECT id from RecordType where Name ='Orders'].Id;
        Opportunity objOpp=new Opportunity(Name='Opportunity1',StageName='Prospecting',CloseDate=closedDate,AccountId=lstAccs[0].Id,Pricebook2Id = objPriceBook.Id,
                                          RecordTypeId=oppRecordTypeId,Viene_de__c=lstAccs[0].Id,Email_de_Contacto__c='dummyOpp@email.com',
                                          Codigo_Postal_de_Envio__c='tesage',Calle_de_Envio__c='tesst',Contacto_Destinatario_Mens__c='cpntacto',
                                          Ciudad_de_Envio__c='ciudad',Pais_de_Envio__c='Pais',Provincia_de_Envio__c='provincia',Telefono__c='1244556677',
                                          Email_Destinatario_Mens__c='dummyOpp1@email.com');
               
        insert objOpp;
    system.debug('***objOpp***'+objOpp.Pricebook2Id);
    //Creating PriceBookEntry Records
        List<PricebookEntry> lstPriceBookEntry=new List<PricebookEntry>();
        PricebookEntry standardPrice = new PricebookEntry(Pricebook2Id = standardPB.Id, Product2Id = objProd.Id, UnitPrice = 10000, IsActive = true, UseStandardPrice = false);
        lstPriceBookEntry.add(standardPrice);
        
        PricebookEntry pbe = new PricebookEntry(Pricebook2Id=objOpp.Pricebook2Id,Product2Id = objProd.Id, UnitPrice = 10000, IsActive = true, UseStandardPrice = false);
        lstPriceBookEntry.add(pbe); 
     insert lstPriceBookEntry;
    
        PriceBookEntry pbe2=[select Id, name,Pricebook2Id from Pricebookentry WHERE Pricebook2Id=:objOpp.pricebook2Id];
        system.debug('***pbe2.Id***'+pbe2.Pricebook2Id);
        
        //Creating Opportunity Line Item records
        List<OpportunityLineItem> lstOppItems=new List<OpportunityLineItem>();
        OpportunityLineItem objLineItem=new OpportunityLineItem(OpportunityId=objOpp.Id,Quantity=2,UnitPrice = 7500,PriceBookEntryId=pbe2.Id,Description = '2007 CMR #4 - Anti-Infectives');
        lstOppItems.add(objLineItem);
        
        if(!lstOppItems.isEmpty())
        {
           insert lstOppItems;  
            
        }  
    }

The pricebookId is same and verified using debug statements.Still I am facing the above mentioned error.

Any help would be appreciated.

Thanks & Regards,
Harsha BR
Hi All,

I have created a custom object which has a Master detail relationship with Standard Salesforce Event.I am unable to add the custom object as the related list to the Standard Event object.Please let me know the procedure.

Thanks & Regards,
Harsha BR

Thanks & Regards,
Harsha BR
Hi,

I am trying to apply filter dynamically on a custom object by giving link in the visualforce page.It is not working as expected.Below is the code snipnet.


<apex:page standardController="SVMXC__Service_Contract__c"> <p> <a href="/00Oq0000000FuVa?pc0=SVMXC__Service_Contract__c.ID&pn0=eq&pv0={!LEFT (SVMXC__Service_Contract__c.ID,15)}&pc1=Name&pn1=eq&pv1={!SVMXC__Service_Contract__c.Name}" target="_blank">Contract Margin</a> </p> </apex:page>

Please help me to resolve the issue.

Any help would be appreciated.

Thanks & Regards,
Harsha 
Hi,

I am unable to cover the start method of Batch class whoever execute method is covered.Please let me know the approach to be followed.

Thanks & Regards,
Harsha 
Hi,

I have got a requirement to write a test class for the controller which has multiple PageReference methods.
I am not sure about the VF page from which it is been called.

Please let me know the approach to be followed.

Thanks & Regards,
Harsha
Hello,

We have built Live Agent for one of our client.We want to customise the chat end messgaes.

Eg:- If the visitor ends the chat,Message will be "Chat ended by Visitor".Asssuming visitor name as Bob,we want to customise as "Chat needed by Bob"

Eg:- If the Agent ends the chat,Message will be "Chat ended by Agent".Asssuming Agent name as Maria,we want to customise as "Chat needed by Maria"
Is it possible with standard live agent functionality? If No,what is the alternative approach to achieve the requirement?


Thanks & Regards,
Harsha BR
Hi,

Business requirement :-
"Edit" standard button on the Junction object should take to the edit page of the master record insted of Junction object record.

How to achieve the above functionality?

Thanks & Regards,
Harsha BR
Hi ,

I have embedded a Report on a VF page and added the VF page in the Record detail page of a object.
I have used analytics:reportChart tag and dynamically filtering the reports based on the Record ID. It is working as expected.

But, when a user clicks the report name or Refresh Date like "As of Yesterday 4:45 PM", the report is breaking and an instance of Salesforce is opening inside the report.

Please suggest a workaround which disables the click event on Report chart name.

Any help is highly appreciated.

Thanks & Regards,
Harsha BR
 
Hello,

I am using the basic username and password authentication mechanism for integration.

Which is the endpoint URL that needs to set as endpointurl to get the access token and inturn data?

Please check the below code and suggest if any changes are required.

public class AccessToken {
    
    
       private Static final String username = 'test@test.com';
       private static final String password = 'XXXsecuritytoken';
    
      public class deserializeResponse
       {
         public String id;
          public String access_token;
       }
    
   public static void ReturnAccessToken ()
   {
        String reqbody = 'grant_type=password&username='+username+'&password='+password;
         Http h = new Http();
          HttpRequest req = new HttpRequest();
          req.setBody(reqbody);
          req.setMethod('GET');
        req.setEndpoint('https://test.salesforce.com/services/oauth2/token');
          HttpResponse res = h.send(req);
        system.debug('*** Response Body***'+res.getbody() );
         deserializeResponse resp1 = (deserializeResponse)JSON.deserialize(res.getbody(),deserializeResponse.class);
         system.debug('@@@@access_token@@'+resp1 );
          //return resp1.access_token;
   }
}

Any help is much appreciated.

Thanks & Regards,
Harsha BR
 
Hello Everyone,

Salesforce displays the standard message of "No Records to display" if records are not available for the object in the Related list of the Master detail page.

Can we customize the standard salesforce message to "No Records to display today".

Please let me know if this can be achieved.

Thanks & Regards,
Harsha BR
Hi Everyone,

How to enable live agent to 1000 users who belong to a single profile?I need to do this in the production org.

Any help is appreciated.

Thanks & Regards,
Harsha BR
after installing node.js when i am running the command ask deploy i am getting the following error

Profile for the deployment: [default]
Skill Id: amzn1.ask.skill.f0439ae9-befa-4ece-a4c7-293f30e1669f
Skill deployment finished.
Call update-model error.
Error code: 400
{
  "message": "Interaction model is not valid.",
  "violations": [
    {
      "message": "InvalidSlotTypeName: Slot type name \"AMAZON.SearchQuery\" is invalid. The name of a custom slot type must begin with an alphabetic character and can consist only of alphabetic characters or underscores."
    }
  ]
}
How to solve this error
Hi ,

I am doing sorting at the client side in helper class in lightning datatable using the below code. However, I am receiving null values in few columns and that is impacting the sorting of my data. How can I handle the null values to show at the last in the sorted table?

 sortData: function (cmp, fieldName, sortDirection) {
        var data = cmp.get("v.mydata");
        var reverse = sortDirection !== 'asc';
        data.sort(this.sortBy(fieldName, reverse))
        cmp.set("v.mydata", data);
    },
    sortBy: function (field, reverse, primer) {
        var key = primer ?
            function(x) {return primer(x[field])} :
            function(x) {return x[field]};
        reverse = !reverse ? 1 : -1;
        return function (a, b) {
            return a = key(a), b = key(b), reverse * ((a > b) - (b > a));
        }
    },
 
I am going through the trailhead ‘Build a Private Alexa for Business Skill for Salesforce’ and am unable to proceed past the Create Alexa Skills and Lambda Functions with the ASK CLI section. I am on the section to Run a Basic Test Using the ASK CLI Simulator and every time I run the command I get the error “Request to skill endpoint resulted in an error”.
Does anyone know how to overcome this?
 
If I try to create Vivian Torres, as an Account with Record Type, Individual, I get an error message:

"FinServ.AccountTrigger: execution of BeforeInsert caused by: FinServ.MoiExceptionWrapper.ValidationException: The Individual record type isn't available. Contact your administrator for help. (FinServ)"
Hello Everyone,

Facing the below error in test class.

System.DmlException: Insert failed. First exception on row 0; first error: FIELD_INTEGRITY_EXCEPTION, field integrity exception: unknown (pricebook entry is in a different pricebook than the one assigned to the opportunity): [unknown]

Following is the piece of code:-
 public static testmethod void updateAccumulatedPriceTest()
    {
        Date closedDate=System.today()+1;
        Id accRecordTypeId =[SELECT id from RecordType where Name ='Partner VIP'].Id;
        
        //Creating Price book records
        List<Pricebook2> lstPriceBooks=new List<Pricebook2>();
        Pricebook2 objPriceBook=new Pricebook2(Name='VirtualCare',IsActive=true);
        lstPriceBooks.add(objPriceBook);
        insert lstPriceBooks;
        
        //Fetching system standard price book
        Pricebook2 standardPB = [select id from Pricebook2 where isStandard=true];
        
        //Creating an Account records
        List<account> lstAccs=new List<account>();
        Account objAcc=new Account(Name='Test Account',Envios_Automaticos__c=false,Tarifa_Acumulado__c=objPriceBook.Id,
                                   Contact_email__c='dummy@email11.com',RecordTypeId=accRecordTypeId);
        lstAccs.add(objAcc);
        insert lstAccs;
        
        
        //Creating Product records
        List<Product2> lstProducts=new List<Product2>();
        Product2 objProd=new Product2(Name='Product',isActive=true);
        lstProducts.add(objProd);
        insert lstProducts;
        
        

        //Creating the list the opportunities
       List<Opportunity> lstOpps=new List<Opportunity>();
        Id oppRecordTypeId =[SELECT id from RecordType where Name ='Orders'].Id;
        Opportunity objOpp=new Opportunity(Name='Opportunity1',StageName='Prospecting',CloseDate=closedDate,AccountId=lstAccs[0].Id,Pricebook2Id = objPriceBook.Id,
                                          RecordTypeId=oppRecordTypeId,Viene_de__c=lstAccs[0].Id,Email_de_Contacto__c='dummyOpp@email.com',
                                          Codigo_Postal_de_Envio__c='tesage',Calle_de_Envio__c='tesst',Contacto_Destinatario_Mens__c='cpntacto',
                                          Ciudad_de_Envio__c='ciudad',Pais_de_Envio__c='Pais',Provincia_de_Envio__c='provincia',Telefono__c='1244556677',
                                          Email_Destinatario_Mens__c='dummyOpp1@email.com');
               
        insert objOpp;
    system.debug('***objOpp***'+objOpp.Pricebook2Id);
    //Creating PriceBookEntry Records
        List<PricebookEntry> lstPriceBookEntry=new List<PricebookEntry>();
        PricebookEntry standardPrice = new PricebookEntry(Pricebook2Id = standardPB.Id, Product2Id = objProd.Id, UnitPrice = 10000, IsActive = true, UseStandardPrice = false);
        lstPriceBookEntry.add(standardPrice);
        
        PricebookEntry pbe = new PricebookEntry(Pricebook2Id=objOpp.Pricebook2Id,Product2Id = objProd.Id, UnitPrice = 10000, IsActive = true, UseStandardPrice = false);
        lstPriceBookEntry.add(pbe); 
     insert lstPriceBookEntry;
    
        PriceBookEntry pbe2=[select Id, name,Pricebook2Id from Pricebookentry WHERE Pricebook2Id=:objOpp.pricebook2Id];
        system.debug('***pbe2.Id***'+pbe2.Pricebook2Id);
        
        //Creating Opportunity Line Item records
        List<OpportunityLineItem> lstOppItems=new List<OpportunityLineItem>();
        OpportunityLineItem objLineItem=new OpportunityLineItem(OpportunityId=objOpp.Id,Quantity=2,UnitPrice = 7500,PriceBookEntryId=pbe2.Id,Description = '2007 CMR #4 - Anti-Infectives');
        lstOppItems.add(objLineItem);
        
        if(!lstOppItems.isEmpty())
        {
           insert lstOppItems;  
            
        }  
    }

The pricebookId is same and verified using debug statements.Still I am facing the above mentioned error.

Any help would be appreciated.

Thanks & Regards,
Harsha BR
Hi All,

I have created a custom object which has a Master detail relationship with Standard Salesforce Event.I am unable to add the custom object as the related list to the Standard Event object.Please let me know the procedure.

Thanks & Regards,
Harsha BR

Thanks & Regards,
Harsha BR
Hi,

I am trying to apply filter dynamically on a custom object by giving link in the visualforce page.It is not working as expected.Below is the code snipnet.


<apex:page standardController="SVMXC__Service_Contract__c"> <p> <a href="/00Oq0000000FuVa?pc0=SVMXC__Service_Contract__c.ID&pn0=eq&pv0={!LEFT (SVMXC__Service_Contract__c.ID,15)}&pc1=Name&pn1=eq&pv1={!SVMXC__Service_Contract__c.Name}" target="_blank">Contract Margin</a> </p> </apex:page>

Please help me to resolve the issue.

Any help would be appreciated.

Thanks & Regards,
Harsha