• #30915
    Forcetalks

    What are the effects of using the transient keyword in Visualforce Page?

    What are the effects of using the transient keyword in Visualforce Page?

     

    #30956
     Avnish Yadav #138
    Forcetalks

    Hello Chanchal,

    Use the transient keyword to declare instance variables that can’t be saved, and shouldn’t be transmitted as part of the view state for a Visualforce page.

    For example- Transient Integer currentTotal;
    You can also use the transient keyword in Apex classes that are serializable, namely in controllers, controller extensions, or classes that implement the Batchable or Schedulable interface. In addition, you can use transient in classes that define the types of fields declared in the serializable classes. – Salesforce

    Thanks.

    #30957
     Prachi #652
    Forcetalks

    Hello Chanchal,

    We Use the transient keyword to declare instance variables that can’t be saved, and shouldn’t be transmitted as part of the view state for a Visualforce page.

    You can also use the transient keyword in Apex classes that are serializable, namely in controllers, controller extensions, or classes that implement the Batchable or Schedulable interface. In addition, you can use transient in classes that define the types of fields declared in the serializable classes.

    Thanks.

Viewing 3 posts - 1 through 3 (of 3 total)

Please to reply to this topic.

CONTACT US

We're not around right now. But you can send us an email and we'll get back to you, asap.

Sending

About Us

Forcetalks is a Salesforce collaboration platform for coders & developers, geeks & nerds, consultants & business heads, admins & architects, managers & marketers and of course the business owners. A community where you can learn from, where you can contribute to. For you. For Salesforce. Read More...

Copyright 2020 Forcetalks. All Right Reserved.

Log in with your credentials

or    

Forgot your details?