Forum Replies Created

Page 18 of 21
  • Avnish Yadav

    Member
    August 2, 2018 at 1:42 pm in reply to: What is the difference between JSON and JSONP in Salesforce?

    Hi Suniti,

    JSON: JSON is a simple data format used for communication medium between different systems
    JSONP: It is a methodology for using that format with cross-domain ajax requests while not being affected by the same origin policy issue.

    Thanks.

  • Avnish Yadav

    Member
    August 2, 2018 at 1:39 pm in reply to: What are the elements of a SOAP message in Salesforce?

    Hi Sanjana,

    A SOAP message is an ordinary XML document containing the following elements:

    1. An Envelope element that identifies the XML document as a SOAP message
    2. A Header element that contains header information
    3. Body element that contains call and response information
    4. A Fault element containing errors and status information

    Thanks.

  • Avnish Yadav

    Member
    August 2, 2018 at 1:07 pm in reply to: Why should we use it from Command Line Interface Data Loader?

    Hello,

    Data Loader is a great native tool provide by the Salesforce to insert, upsert, update, export and delete data. Standard Data Loader wizard needs interaction, however, there are many scenarios where we need to perform these data loading tasks repeatedly like every night 1:00 AM (Nightly Services) or something. So, for these situations, we can use standard data loader tool from Command line.

    Thanks.

  • Avnish Yadav

    Member
    August 2, 2018 at 12:41 pm in reply to: Name important annotations used in JAX-RS API in Salesforce

    Hello Suniti,

    Some of the important JAX-RS annotations are:

    @Path: used to specify the relative path of class and methods. We can get the URI of a web service by scanning the Path annotation value.
    @GET, @PUT, @POST, @DELETE, and @HEAD: used to specify the HTTP request type for a method.
    @Produces, @Consumes: used to specify the request and response types.
    @PathParam: used to bind the method parameter to path value by parsing it.

    Thanks.

  • Hello Madhulika,

    The properties inside the LoginScopeHeader element concern the authentication of Self-Service and Customer Portal users. It specifies your organization ID using the existing login().

    There are two fields inside the LoginScopeHeader:-

    1.  organizationId - The ID of the organization against which you will authenticate Self-Service users.
    2.  portalId - Specify only if user is a Customer Portal user. The ID of the portal for this organization. The ID is available in the Salesforce user interface:
      a. From Setup, enter Customer Portal Settings in the Quick Find box, then select Customer Portal Settings
      b. Select a Customer Portal name, and on the Customer Portal detail page, the URL of the Customer Portal displays. The Portal ID is in the URL.

    Thanks.

  • Avnish Yadav

    Member
    August 2, 2018 at 7:57 am in reply to: How to integrate Salesforce with Gmail and Outlook?

    Hello Anjali,

    Here is the trail for your question:- https://trailhead.salesforce.com/en/trails/outlook_gmail_integration

    Thanks.

  • Hi Anjali,

    If you have count variable in your controller then you can simply show the output panel if the count is not 0 or greater than 0...
    Refer below code for the same..

    <apex:outputPanel rendered = "{! If(count >0,true, false )">

    Hope this will help you .

    Thanks.

  • Hi Prachi,

    According to the docs, Trigger.new returns a list, which are ordered, and Trigger.newMap returns a map - which are unordered. The docs specifically state you should not rely on the ordering of a map's elements.

    When to use depends on what you're doing - if you have an ID of an object you need to do something with, using the map makes more sense as you can use newMap.get(). Otherwise, you'd have to loop over all the elements in Trigger.new and look for a matching ID. Similarly, if you have multiple loops over each item the trigger is operating on, the list returned by Trigger.new may be the better bet.

    Thanks.

  • Hi Shradha,

    ActionSupport: A component that adds AJAX support to another component, allowing the component to be refreshed asynchronously by the server when a particular event occurs, such as a button click or mouseover.

    Used when we want to perform an action on a particular event of any control like onchange of any text box or picklist.

    Thanks.

     

  • Avnish Yadav

    Member
    August 1, 2018 at 2:04 pm in reply to: Can we modify records directly in Salesforce trigger.new?

    Hi Prachi,

    No. You can't modify it.

    Thanks.

  • Avnish Yadav

    Member
    August 1, 2018 at 11:05 am in reply to: Can we add custom range in Salesforce Filter?

    Hello Anjali,

    Yes, we can add custom range filters in the report by clicking on ADD button above on report (Note: report must open in customize view or in edit view).

    Thanks.

  • Avnish Yadav

    Member
    August 1, 2018 at 10:29 am in reply to: When should a Salesforce Org consider using Record types?

    Hi Prachi,

    Record types let you offer different business processes, picklist values, and page layouts to different users. You might create record types to differentiate your regular sales deals from your professional services engagements, offering different picklist values for each. Or you might display different page layouts for your customer support cases versus your billing cases. - Salesforce

    Scenario - if a certain profile needs to see 2 different page layouts on the same object, then 2 record types will need to be created.

    Hope this will help you.

    Thanks.

  • Hi Prachi,

    It would totally depend on your requirement on what will help you achieve your target.
    If you want the child to be deleted, go for master-detail.
    If you want the child to inherit the sharing setting of the parent, go for master-detail.
    If the child required to have a mandatory parent, go for master-detail (though this can be implemented using lookups as well) otherwise go for lookup.

    Thanks.

  • Hello Madhulika,

    Chatter API is REST API for Chatter to display Salesforce data, especially in mobile applications. Responses are localized, structured for presentation, and can be filtered to contain only what the app needs.

    Connect API provides apex classes for accessing the same data available in Chatter REST API. Use Chatter in Apex to create custom Chatter experiences in Salesforce

    Thanks.

  • Avnish Yadav

    Member
    July 31, 2018 at 1:51 pm in reply to: What are the Different API's in Salesforce?

    Hello Shradha,

    Different API provided by Salesforce:-

    1. REST API - Access objects in your organization using REST.
    2. SOAP API - Integrate your organization’s data with other applications using SOAP.
    3. Tooling API - Build custom development tools for Force.com applications. Coming soon!
    4. Chatter REST API - Access Chatter feeds and social data such as users, groups, followers, and files using REST.
    5. Bulk API - Load or delete large numbers of records.
    6. Metadata API - Manage customizations in your org and build tools that manage the metadata model (not the data, itself).
    7. Streaming API - Provide a stream of data reflecting data changes in your organization.
    8. Apex REST API - Build your own REST API in Apex. This API exposes Apex classes as RESTful Web services.
    9. Apex SOAP API - Create custom SOAP Web services in Apex. This API exposes Apex classes as SOAP Web services.
    10. Data.com API - Data.com provides 100% complete, high-quality data, updated in real-time in the cloud, and with comprehensive coverage worldwide.

    Hope this will give an idea of different API in Salesforce.

    Thanks.

  • Hi Madhulika,

    Hard delete is done by using DataBase.emptyRecycleBin method in the Batch class. Create a sample Batch class as mentioned below and use DataBase.emptyRecycleBin method in the Batch class.

    global class BatchDeletion implements Database.Batchable<sObject>, Schedulable
    {
    global BatchDeletion()
    {
    //constuctor
    }

    global Database.QueryLocator start(Database.BatchableContext bc)
    {
    //query to return all expired Case Share records
    return Database.getQueryLocator([Select id from Account where Name='Test Account12']);
    }

    global void execute(SchedulableContext sc)
    {
    //execute the batch
    BatchDeletion deleteCS = new BatchDeletion();
    ID batchprocessid = Database.executeBatch(deleteCS);
    }

    global void execute(Database.BatchableContext BC, list<sObject> scope)
    {
    System.debug('## deleting '+scope.size()+' case share recs');

    //delete list of expired Case Share records
    delete scope;
    Database.emptyRecycleBin(scope);
    }

    global void finish(Database.BatchableContext BC)
    {
    //no post processing
    /* System.debug('## Batch Job Finished ##');
    UpdateAccountFields m = new UpdateAccountFields ();
    String sch = '20 30 8 10 2 ?';
    system.schedule('Merge Job', sch, m);*/

    }
    }

    Hope this will help you.

    Thanks.

  • Avnish Yadav

    Member
    July 31, 2018 at 8:29 am in reply to: What is the use of variant in Salesforce Lightning Button?

    Hello Anurag,

    Component variants correspond to variants in Lightning Design System. Variants change the appearance of a component and are controlled by the variant attribute.

    variant="brand" - A blue button with white text - Lightning design class="slds-button_brand".

    Thanks.

  • Avnish Yadav

    Member
    July 31, 2018 at 7:18 am in reply to: What are the Applications of Nested Query in Salesforce?

    Hello Chanchal,

    Application of Nested Query:-

    1. For example, you implemented a trigger on Contact, but you want to access account, the nested query can help you and vice versa.
    2.  Finding Second MAX or Second MIN Salary, you have to use the nested query.
    3. GROUP BY clause generally implemented on Nested Query.

    These are the small scenarios, which I know, there is a lot more - application of nested query.

    Thanks.

     

  • Hello Anjali,

    You can use a Set to store ids, which will prevent duplicate records from being processed.

    Example:-

    Set<SObject> setIdobject = new Set<SObject>();

    for(SObject obj: Trigger.new)

    {

    setIdSobject.add(obj.id);

    }

    Thanks.

  • Avnish Yadav

    Member
    July 31, 2018 at 6:55 am in reply to: Is it possible to generate pdf in Salesforce lightning?

    Hello Shaik,

    I just found a good answer for you, here is link:-

    https://gist.github.com/toanshulverma/16244d19ac68364cb75443695d81403b

    Hope this will help you.

    Thanks.

     

  • Hello Madhulika,

    For multi-language use the Language attribute on the apex:Page tab

    <apex:page language="{!$CurrentPage.parameters.lang}">

    replace the Lang parameter with whatever you are using to send the language.

    Thanks.

  • Hello Anjali,

    First of all, you need to activate the Translation Workbench (Setup --> Translation Workbench --> Translation Settings then Activate button). Then, add the language you want to enable.

    When it's done, you have a related list on each custom label where you can add the translation for each activated language.

    Custom label value will be displayed according to the navigation language of the user.

    Thanks.

  • Hello Anjali,

    We use $A.util.toggleClass to add or remove a CSS style on a component or element during runtime.

    To retrieve the class name on a component, use component.find('myCmp').get('v.class'), where myCmp is the aura:idattribute value.

    To append and remove CSS classes from a component or element, use the $A.util.addClass(cmpTarget, 'class') and $A.util.removeClass(cmpTarget, 'class') method

    Thanks.

  • Avnish Yadav

    Member
    July 30, 2018 at 1:41 pm in reply to: What is Live Agent Configuration Settings in Salesforce?

    Hi Shradha,

    Using Live agent, Service representatives can directly chat with customers and resolve the customer issue. Live Agent is a native tool provided by Salesforce which can be setup by point and clicks and no need of programming is needed. For setup information watch videos on youtube.

    Thanks.

     

  • Avnish Yadav

    Member
    July 30, 2018 at 1:38 pm in reply to: What is the use of Salesforce chatter REST API?

    Hi Prachi,

    The Chatter API (also called Chatter REST API) lets you access Chatter information via an optimized REST-based API accessible from any platform. Developers can now build social applications for mobile devices, or highly interactive websites, quickly and efficiently.

    Thanks.

Page 18 of 21