You need to sign in to do that
Don't have an account?

Removing None Option in PickList visualforce apex
i have created an object with name PS_Detail__c .in this custom object i created a custom field of picklist type.in this picklist i defined two values Dollar ,Unit. when i go to P/S Detail Tab for creating a new PS_Detail__c object then i get None also as a value in picklist field .i want only Dollar and Unit as Picklist values .some one please help how to remove this None from Picklist
Since your picklist field is on a Visualforce page, you can use some jQuery magic...
Give your field a unique id.
Then, remove the option with the blank value as follows:
We can not remove None option directly becaus this inputfield ( pickiist Type). We need to make our custom pick list .
Here is a way to create custom pick list
$('[id*=myPicklist] option[value=""]').remove();
});
Please refer below link. It worked for me!
http://mrjavascript.blogspot.in/2013/04/blog-post.html