Forum Replies Created

Page 4 of 4
  • Anurag

    Member
    July 31, 2018 at 1:41 pm in reply to: What is the use of pagination in Visualforce?

    Hi Sanjana,

    We mainly use pagination to divide a large set of records into small groups by separating it into pages such that one page would contain only particular number of records .The division of records would depend on us.

  • Anurag

    Member
    July 31, 2018 at 1:36 pm in reply to: Why there is no before-undelete event in Salesforce Triggers?

    Hi Sanjana,

    Triggers fire as the result of an action on an object . With an object that is deleted there are really no before actions you can take, you can only undelete it. The only action available on a deleted object is after you undelete it hence the after undelete.

  • Anurag

    Member
    July 31, 2018 at 1:33 pm in reply to: What are the Salesforce annotations? List all of them.

    Hi Madhulika,

    The main use of annotation is to instruct the compiler that the class is to be used as the specific class as defined by the annotation. Annotations are defined with an initial @ symbol, followed by the appropriate keyword.

    Apex supports the following annotations.
    @AuraEnabled
    @Deprecated
    @Future
    @InvocableMethod
    @InvocableVariable
    @IsTest
    @ReadOnly
    @RemoteAction
    @SuppressWarnings
    @TestSetup
    @TestVisible

    Apex REST annotations:
    @RestResource(urlMapping='/yourUrl')
    @HttpDelete
    @HttpGet
    @HttpPatch
    @HttpPost
    @HttpPut

  • Anurag

    Member
    July 30, 2018 at 11:13 am in reply to: What is the use of System.assertEquals() in Salesforce?

    Hi Avnish,

    We use System.assertEquals in our test methods basically to check whether the two values are equal or not.One of the value is said to be expected value which we expect while making dummy variables and giving values to it. The second is the actual result which we get on passing the variable in the given class method. System.assertEquals() returns true if the values are equal and throws an exception message(which is also provided by us) in case they are unequal.

  • Anurag

    Member
    July 30, 2018 at 11:05 am in reply to: When to use before vs after Triggers in Salesforce?

    Hi Sanjana,

    We use before triggers when we want to update any field or validate any record before they are saved to the database.After triggers are used when we wish to access any field values after they are saved to the database.Just remember, we cannot update a field value in after trigger because once they are saved to the database, values become read-only and we cannot make changes to them.

  • Anurag

    Member
    July 30, 2018 at 11:00 am in reply to: What is the use of httpPATCH in Salesforce?

    Hi Sanjana,

    HttpPatch methods are used to do update operation in Salesforce. You have to write class with @httpPatch method which will be used by end user.

  • Anurag

    Member
    July 27, 2018 at 12:47 pm in reply to: Can a trigger make a call to Salesforce Apex callout method?

    Hi Sanjana,

    There is only one way to make a callout from a trigger and that is to run it asynchronously by using a future method.The reason for it is that the apex trigger restricts database transaction until the callout is completed and the time limit for this is up to 120 seconds.Future methods execute asynchronously i.e. one does not need to wait for a response. Hence, it can be used. Also remember that in order to make a callout from an apex trigger through future method, we need to enable a callout from future by passing an extra parameter “Callout=true”.

  • Hi Sanjana,

    Rendered-This attribute is used to display a particular filed or section based on boolean value.

    ReRender- This is to reload some fields, or sections after some operation. Advantage of it is that the whole page is not refreshed and only a portion(the one which is ReRendered) is refreshed.

           RenderAs- This is to render a VF page as PDF or some other format.

     

  • Hii Prachi,

    First, you need to add an ID to that particular component and then you can access it in java script by using a command - 'document.getElementById("ID"); ' .

  • Hi Anjali,

    You can find base Lightning components in the lightning namespace to complement the existing ui namespace components. In instances where there are matching ui and lightning namespace components, we recommend that you use the lightning namespace component. The lightning namespace components are optimized for common use cases. Beyond being equipped with the Lightning Design System styling, they handle accessibility, real-time interaction, and enhanced error messages.

  • Hi Chanchal,

    Debug logs are used to point out user debug statements in apex classes triggers etc. System log is used to refer all the logs that is recorded like workflow fire, test class run etc.. but on a very high level both are same .

  • Anurag

    Member
    July 25, 2018 at 1:23 pm in reply to: What is the difference between CLI and CLIQ?

    Hii Chanchal,

    The CLI is the ApexDataLoader utility(with a GUI) provided by SFDC and the latter is the Command-Line Interface(CLI) of the ApexDataLoader. You could use the CLI version in your external applications.

  • Hii Anjali,

    In a lightning component, the client side is a component page and the java script controller and the server side is the apex controller and the databases. Lightning component has an  advantage over the visualforce page in that it provides the java script controller over the client side.

  • Anurag

    Member
    July 24, 2018 at 2:43 pm in reply to: What are the different Salesforce Lightning component bundles?

    Hii Chanchal,

    These are the following:

    a. Component
    b. Controller
    c. Helper
    d. Style
    e. Document
    f. Design
    g. SVG
    h. Rendre

  • Hii Madhulika,

    Managed Packages are the ones in which the code is hidden and cannot be edited by the client who has bought it. It can simply be used by them. As contrary to it, unmanaged packages can  easily be edited by the client in their org  where it has been installed because it is open to them.

  • Anurag

    Member
    July 20, 2018 at 1:13 pm in reply to: What are the different types of Sandbox in Salesforce?

    Hii Anjali,

    There are various types of Sandbox available such as Developer Sandbox,Developer Pro Sandbox,Partial copy Sandbox and Full Sandbox which are available in  Professional, Enterprise, Performance, Unlimited, and Database.com Editions.

  • Hii Anjali,

    There is not a specific problem encountered while calling a batch from a trigger. But there are few limitations that we should keep in mind which calling the batch class. For instance, we can only have 5 batch jobs queued or executing at once. So we should be aware of the potential limits. If our trigger calls batch jobs each time, then we could quickly exceed that limit.

  • Anurag

    Member
    July 20, 2018 at 12:57 pm in reply to: What are context variables in Salesforce Triggers?

    Hii Sanjana,

    Context variables, as the name implies, refers to the fact that what the context of the trigger fire is . These are basically the implicit variables that that allow developers to access run time context. Some of the examples of context variables are isInsert, isUpdate, isDelete etc.

  • Anurag

    Member
    July 19, 2018 at 3:21 pm in reply to: What are the limitation of Salesforce apex scheduler?

    Hii Anjali,

    One of the limitations of Apex Scheduler is that we can only have 100 scheduled Apex jobs at one time. We must use extreme care if we are planning to schedule a class from a trigger. We must be able to guarantee that the trigger won’t add more scheduled classes than the limit. In particular, consider API bulk updates, import wizards, mass record changes through the user interface, and all cases where more than one record can be updated at a time.

  • Hii Avnish,

    Yes, it is important to denote a test class with a separate syntax so that the compiler can understand that its a class where we are going to perform a test. But, instead of using an annotation @isTest, we can also use 'testmethod'  in a method name.

     

  • Anurag

    Member
    July 19, 2018 at 3:01 pm in reply to: Explain the use of OutBound Message in Salesforce.

    Hi Anjali,

    Outbound messaging is part of the workflow rule functionality in Salesforce. Workflow rules watch for specific kinds of field changes and trigger automatic Salesforce actions, such as sending email alerts, creating task records, or sending an outbound message to external services.

  • Anurag

    Member
    July 18, 2018 at 1:21 pm in reply to: Is binding between SOAP and WSDL possible in Salesforce?

    Hi Chanchal,

    We use the WSDL file in our Salesforce org to generate an Apex Class which we use to make a callout in SOAP.

  • Anurag

    Member
    July 17, 2018 at 11:57 am in reply to: How can we call future method from Salesforce batch apex?

    Hello Prachi,

    We cannot call future methods from any batch class or any other future class because both are asynchronous methods and the exact time of their execution is not known so adding an asynchronous method to an already existing one is not considered best practice. Besides, it is not allowed in Salesforce.

  • Anurag

    Member
    July 17, 2018 at 11:49 am in reply to: What is the use of HTTP POST in Salesforce?

    Hello Sanjana,

    There are various methods used while making a callout through HTTP. The HTTP-'POST' method is used when we are to post a data to the server or create a resource for a client to use.

  • Anurag

    Member
    July 17, 2018 at 11:41 am in reply to: What is the use of AuraEnabled Annotation in Salesforce?

    Hello Sanjana,

    Writing this annotation makes the method availaible in Lightning component. It simply enables the access to that particular Apex class through the java script code that we have written

Page 4 of 4