Sign up ×
Salesforce Stack Exchange is a question and answer site for Salesforce administrators, implementation experts, developers and anybody in-between. It's 100% free, no registration required.

I need to save a value in a Salesforce Instance which should be universally accessible (In VisualForce Pages, Apex Classes). An example would be to save the account ID to link all contacts (from the apex code), username/password combination and so on. Out of the three methods listed below which one is the best?

  1. Static Resourcce
  2. Static Class
  3. Custom object with a single record (Get the value be querying the field)
share|improve this question

1 Answer 1

None of them.

A custom setting is what you are looking for. They are available to Apex code, Visualforce, and Formulas. Take a look at the docs and examples

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.