0

I have below method in a public with sharing class. In the method, I need to use an integer but unable to declare that. Can someone please help me in integer declaration here?

Snippet:

public with sharing class GMAProfileCon_SN {

  public void Add()
    {   
        count = count+1;
        //addMore();      
    }
1

1 Answer 1

0
public with sharing class GMAProfileCon_SN {

    private Integer count;

    public GMAProfileCon_SN(){
        this.count = 0;
    }
    public void Add()
    {   
        this.count = this.count+1;
        //addMore();
    }
}

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .