You might be able to uncheck the "administer nodes" permission and ensure that the "edit any <content type>" permission is checked for role2. This would probably circumvent the permission denied error, although I'm not entirely certain as it is a bit of an edge case.
If all else fails, you could use form_alter to hide and unhide the appropriate fields based on the user role. This would require creating a module and implementing hook_form_alter (http://api.drupal.org/api/function/hook_form_alter/6). The list could help step you through how to do that.
Best,
William
Hellos,
New to drupal. I have created a custom cck form, where information is filled by different users on the same form
User 1(with role 1) fills cck field A, B C, then user 2(with role2) fills in cck fields D and E. I have set permissions for the different roles where under the "content_permissions module" to allow users onl to fill fields that they have permissions to fill. User 1 works well and creates the node and fills only their fields.
When user 2 accesses the same node, they get "permission denied error". I solved this by enabling "administer nodes" under the "node module" permissions.
The problem I am facing is with this enabled, user 2 can edit user 1 fields. How can I stop this?
Thanks
--
[ Drupal support list | http://lists.drupal.org/ ]