Don't have an account?
Search for an answer or ask a question of the zone or Customer Support.
You need to sign in to do that
Sign in to start searching questions
Signup for a Developer Edition
Sign in to start a discussion
List<Games__C> mcs = Games__c.getall().values(); boolean textField = null; if (mcs[0].GameType__c == 'PC') { textField = true; } system.assertEquals(textField, true);
SObjectType csType = Schema.getGlobalDescribe().get('YOUR_CUSTOM_SETTINGS_NAME'); Map<String,Schema.SObjectField> csfields = csType.getDescribe().fields.getMap(); System.debug(csfields.keySet());
Find more details in https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/apex_methods_system_custom_settings.htm
Thank You for the suggestion.
Dynamically I have to take fields.
I can't specify the field name.
With Regards,
Nisha
Thank You for the help.
Actually I have to take some of the fields from the keySet() and have to add it a new map.
How to do that.
With Regard,
Nisha
How to get the value for an field from the keySet().
I don't want the value for all fields but value for some fields in the object.
And I have to store the selected key and value to another map.