function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
RIteshMRIteshM 

ObjectPermissions object retriving object access related to a profile

i am following this tutorial http://www.salesforce.com/us/developer/docs/api/Content/sforce_api_objects_permissionset.htm . i read this and have to get the information related to a profile . that a particular profile have access to which level to a object .for example Authenticated website have access to which level to a object say Account  have read only access or read/write or viewall etc and then after reading  giving it all kind of access read,write,viewall,modifyall etc.for getting object permissions i write a query

 

List<ObjectPermissions> oo1 = [SELECT Id FROM ObjectPermissions WHERE Parent.profileId = :TargetProfileId] ;

 

but i dont know any thing about ObjectPermissions object .how to get access properties related to a object for example i want to access properties of object Account and then want to modify it.can any one tell how to use this object and the properties related to this Object please guideline so i can proceed further