• stayal1.2953349221005618E12
  • 0 Points
  • Member since 2011

  • Chatter
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 1
  • 2

Below is the scenario where i'm stuk.


I want to get picklist values based on recordtype for a object (account) but i'm not able to get it .

below is some code through which i have tried to get that.


RecordType rttt = [SELECT Id,Name FROM RecordType WHERE SobjectType='Account' and name='newrecformanaged'];

List<SelectOption> options = new List<SelectOption>();
Schema.DescribeFieldResult fieldResult = account.rttt.Type.getDescribe();
List<Schema.PicklistEntry> ple = fieldResult.picklistValues;
for(Schema.PicklistEntry p : ple)
options.add(new SelectOption(p.Value, p.Value));



here is salesforce link that have some suggession:http://hisrinu.wordpress.com/2011/04/20/advantage-of-describe-calls/


any help will be appreciable


Hello everyone.

I have a querstion about the creation of fields in salesforce.

It's possible I create a custom field in object Task? If it's possible as I do?

Thx for replies.

Can the new Dynamic Visualforce Components be used to generate an outputText tag with merge fields, such that the merge fields are resolved when the page is displayed?  Something like this.


<apex:page standardController="Account" extensions="dynamicSample">
Name: <apex:dynamicComponent componentValue="{!dynamicName}"/> 


public class dynamicSample {
public Component.Apex.OutputText getName () {
String x = new Component.Apex.OutputText;
x.value = "{!Account.Name}" ;
return x ;