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
Giddamreddi ReddyGiddamreddi Reddy 

sharing rules for traning coordinator and project.

Project custom object records should only be seen by the owner of the record and users above the owner on the role hierarchy. However, for some Project records, the Training Coordinator must also have Read Only visibility to the Project record.

Create a custom picklist field on the Project object called “Priority” with the following values: High, Medium, and Low. Then create a criteria-based Sharing Rule for Project records where the Priority = High to share those records with the Training Coordinator role.
Best Answer chosen by Giddamreddi Reddy
Giddamreddi ReddyGiddamreddi Reddy
sonam see
1) u create project obj and API   project__C.
2) choose date type of project...text (not for any number)
3).in this create field priority with API priority__C.
4) in security controlls owd set  public read only..on project obj& also give sharing rule name   as ur wish.(i am given that private)
5) if  all ready exist  Training Coordinator in ur role highrarchey then don.t add..its..if not there add  Training Coordinator.on under ceo role. 
then u got 500 points........ok bye..

All Answers

SonamSonam (Salesforce Developers) 
Can you please help understand if you are seeing any errors with this challenge?
SFDC@RnSFDC@Rn
Could you be more specific?
Giddamreddi ReddyGiddamreddi Reddy
  • hai sonam ,see this task In Trailhead    sharing rules..block (see  task below)
Project custom object records should only be seen by the owner of the record and users above the owner on the role hierarchy. However, for some Project records, the Training Coordinator must also have Read Only visibility to the Project record.

Create a custom picklist field on the Project object called “Priority” with the following values: High, Medium, and Low. Then create a criteria-based Sharing Rule for Project records where the Priority = High to share those records with the Training Coordinator role.
Somnath LokeshSomnath Lokesh
Was there an answer for this?  Because I keep getting the following error "Challenge not yet complete... here's what's wrong: 
The sharing rule did not behave as expected.".
Giddamreddi ReddyGiddamreddi Reddy
samanth lokesh  tere is solution.. try agine first read task  complete understanding model..then solve

 i got points this ..ok
 
Giddamreddi ReddyGiddamreddi Reddy
Sonam, in first time i got error but  when i read with clarity  then i solve it.. first i got challege not yet complete  there is error "sharing role bheve does.t expected" ..so and soo..
 
Ghanshyam Yadav01Ghanshyam Yadav01
hi Giddamreddi Reddy, m facing same issue can u explain with some snapshots,, or u can share the photo of sharing rules page.
SonamSonam (Salesforce Developers) 
Hi Ghanshyam, please share the errror you are recieving so we can suggest you the steps you can try to ressolve this.
Ghanshyam Yadav01Ghanshyam Yadav01
Hi Sonam, alot of thanks for your +ve response, i have already solved that challange,,, if you wants the solution then i can share on this portal


Regards,
Ghanshyam
SonamSonam (Salesforce Developers) 
Sure, please go ahead and share so others can also benefit from it.
Giddamreddi ReddyGiddamreddi Reddy
sonam see
1) u create project obj and API   project__C.
2) choose date type of project...text (not for any number)
3).in this create field priority with API priority__C.
4) in security controlls owd set  public read only..on project obj& also give sharing rule name   as ur wish.(i am given that private)
5) if  all ready exist  Training Coordinator in ur role highrarchey then don.t add..its..if not there add  Training Coordinator.on under ceo role. 
then u got 500 points........ok bye..
This was selected as the best answer
Ivan Hernandez 15Ivan Hernandez 15
I'm Having the same problem, i'm doing all the steps , but i'm having this error:
Challenge not yet complete... here's what's wrong:
The sharing rule did not behave as expected.
project object
User-added image
sharing setting
sharing setting
sharing rule
User-added image
please Help
SonamSonam (Salesforce Developers) 
@Ivan, Your sharing rule gives both Read/Write access however, the challenges says they should be able to only read the record( the Training Coordinator must also have Read Only visibility to the Project record.).

Change the Access level to read only and see if that helps..
Ivan Hernandez 15Ivan Hernandez 15
now I have "Public Rean Only" in Organization-Wide Defaults
and I set  Read Only in the Sharing Rule's Access Level
I still doesn't work  =(
User-added image
Ivan Hernandez 15Ivan Hernandez 15
and what about the level securtity of the field Priority , does it affect?
User-added image
Vivek rajVivek raj
somebdy plzzz clarify its solution....i m getting d same error ...the sharing role does not behave as expected.
Jeremy GaisieJeremy Gaisie
Has anyone managed to solve this yet? Similarly to many others here, i've completed all steps but am confronted with the same error..
Anthony BenitezAnthony Benitez
I was on the same situation. Setting Project's organization-wide default to private worked for me, have you tried that?
Jadden ResendizJadden Resendiz
Everyone, check your organization wide defaults and make sure it is "Private" for project. You may have to play around with the selections as I did and I eventually got 500 points. 
Rodney AndersonRodney Anderson

I was also having trouble with this but finaly got it to work.

1) Created my 'Project' object with API 'Project__c' ( This was actually done in a previous lesson for this Data Security Badge)
      *By Setup --> Create --> Objects --> New Custom Object

2) 'Project' Name data type = Text(80)

3) Created a custom field called 'Priority' on the 'Project​' Object with data type of 'PickList' (API name should be 'Priority__c')

4) Added '​High', 'Medium', and 'Low' text to the picklist values

5) Created a Role called 'Training Coordinator' (This was actually done in the previous lesson for Data Security called 'Creating a Role Hierarchy')
      *By Setup --> Manage Users --> Roles​  --> Set Up Roles (Choose the Role this role needs to report to) --> Add Role

6) Created the Sharing Rule
      * By Setup --> Security Controls --> Sharing Settings ​--> Manage sharing settings for 'Project' (drop list)--> Project Sharing Rules --> New

7) STEP 1:​Label = 'Project Sharing Rule', Rule Name = 'Project_Sharing_Rule'
    STEP 2: Rule Type = Based Criteria
    STEP 3:​​ Field = 'Priority', Operator = 'equals', Value = High
    STEP 4: Share with 'Roles' , and select 'Training Coordinator'
    STEP 5: Access Level = 'Read Only'​​

8)  Make organization wide defaults "Private"​
     *By Setup --> Security Controls --> Sharing Settings ​--> Edit --> Project default internal access = 'Private'

Vineeth PydimarryVineeth Pydimarry
People map the hierchy with Rold and Sub.. The key is Role which needs to be set to Training Coordinator
Yohan Tierney 1Yohan Tierney 1
I can't save for some reason when I get to the sharing rule...   Does anyone know why?
MD SHAHABMD SHAHAB


hi Ghanshyam Yadav01, m facing same issue can u explain with some snapshots,, or u can share the photo of sharing rules page.
MD SHAHABMD SHAHAB
1User-added image

2User-added image

3User-added image


4User-added image
MD SHAHABMD SHAHAB

somebdy plzzz clarify its solution....i m getting d same error ...the sharing role does not behave as expected
Niño Wilbert SesgundoNiño Wilbert Sesgundo

Thank you! Rodney Anderson. Works for me!
Andrea Sonderfan 1Andrea Sonderfan 1
My custom field for Priority will not show up as an option in the field for project sharing rule.  What did I do wrong?
shivam sheelshivam sheel
 Guys...read the first line of the challenge carefully.... it says ​Project custom object records should only be seen by the owner of the record and users above the owner on the role hierarchy  which means organization wide defaults have to be private so that ONLY THE PERSON WHO OWNS THE RECORDS AND ABOVE IN HEIRARCHY CAN VIEW THOSE..... by default it is set to public.... 
Follow the steps to complete the challenge... these steps will satisfy those too getting different errors saying the SHARING ROLE DOES NOT BEHAVE AS EXPECTED...

step 1: 
 create a custom object named "Project' giving out the api "Project__c"
             setup---->create---->objects----->new custom object----->label (type--> Project) [dont't do anything else as by default the data type is                    text itself ].
             click on save and you have now successfully created the custom project object with the api as required. 

step 2:   now go to the custom field and relationship  (scroll down u'll see) and click on new. Select the picklist and give the label as Priority 
             
Give the values of the picklist as High(press enter) Medium(press enter) Low(press enter).
             The next page you will see two fields visible and read only . Select the visible box and next. 
             Thus now you have created a custom field Priority with api Priority__c which you can clearly see after saving.

step 3:   I'm considering that you must have already created the role of the Training Coordinator as in the previous challenge. If not please go                 back to the previous challenge and create the roles.If you still have problems do tell I'll help you out.

            NOW THE MAIN PARTS


step 4:    creating the sharing rule--------
          
                security control--->sharing settings
                
               On that page you will see  Manage sharing settings for :   from the droplist select the Project

              After you have done these..... scroll down and you will see Project Sharing Rules and click on NEW 

             you will see various steps given on those page-------
   
                                   step 1: Rule Name
                                               Give any label name of your choice and the corresponding rule name will be automatically generated.

                                   Step 2: Select your rule type
                                               Check on the option given as Based on criteria 

                                    Step 3: Select which records to be shared  
                                                  Select the     Field   as    Priority    Operator     as    Equals          Value    as   High 
                                                  
( the value oh high can be obtained by clicking the search icon just next to the field ,search and insert the                                                             value or you can type too).


                                     Step 4: Select the users to share with
                                                      Share with: (droplist and select Roles)      -----Select One---- (droplist and select Training Coordinator)

                                    Step 5: Select the level of access for the users
                                                      
Let the access level as Read Only itself.
                                                       and save.


              Our job is not over yet . People getting error messages as SHARING ROLE DOES NOT BEHAVE AS EXPECTED...​  is because you                 have performed well and accurately till step 4 but have not given the  Organization-wide defaults settings as private.
              
To change the settings follow the step 5 which is much similar to the step 4.

step 5:     creating the sharing rule--------
          
                security control--->sharing settings
                
               On that page you will see  Manage sharing settings for :   from the droplist select the Project

              
After you have done these.....
              
              you'll see Organization-wide defaults   , and click on EDIT.

              and set the Default Internal Access  to  Private . [ this is the thing which most of us miss] ,...because according to the first line of the                    challenge it should ve visible only by the user and upper level of heirarchy.
      


THANK YOU...
 
Smitha GeorgeSmitha George
Thanks a lot. This worked well to solve the error "sharing role does not behave as expected".
Imtiyaz Ali 16Imtiyaz Ali 16
Thanks alot Mr.Rodney Anderson.
CloudyJoshCloudyJosh
MAKE SURE that you have "Roles" and NOT "Roles and Subordinates" selected in the criteria section, otherwise this will not work! I had everything down correctly except I selected "Roles and Subordinates" then selected "Training Coordinator" and that error kept popping up. Took me two days to figure this out.
Jeremy Snow 1Jeremy Snow 1
Even though it says to NOT have access to "Public Read/Write", it would only work when I had access set to "Private". "Public Read Only" would not work.
Thomas MasnyThomas Masny
THX a lot Shivam Sheel!
Selva lingamSelva lingam
shivam sheel Thanks a lot :) :) 
Srizan GangolSrizan Gangol
@CloudyJosh thats what I was doing wrong! Thanks!!
 
bhatt bijalbhatt bijal
y shivam sheel,
 i did same steps as yours still its not working...

step 1:  create a custom object named "Project' giving out the api "Project__c"
             setup---->create---->objects----->new custom object----->label (type--> Project) [dont't do anything else as by default the data type is                    text itself ].
             click on save and you have now successfully created the custom project object with the api as required. 

step 2:   now go to the custom field and relationship  (scroll down u'll see) and click on new. Select the picklist and give the label as Priority 
             Give the values of the picklist as High(press enter) Medium(press enter) Low(press enter).
             The next page you will see two fields visible and read only . Select the visible box and next. 
             Thus now you have created a custom field Priority with api Priority__c which you can clearly see after saving.

step 3:   I'm considering that you must have already created the role of the Training Coordinator as in the previous challenge. If not please go                 back to the previous challenge and create the roles.If you still have problems do tell I'll help you out.

            NOW THE MAIN PARTS


step 4:    creating the sharing rule--------
          
                security control--->sharing settings
                
               On that page you will see  Manage sharing settings for :   from the droplist select the Project

              After you have done these..... scroll down and you will see Project Sharing Rules and click on NEW . 

             you will see various steps given on those page-------
   
                                   step 1: Rule Name
                                               Give any label name of your choice and the corresponding rule name will be automatically generated.

                                   Step 2: Select your rule type
                                               Check on the option given as Based on criteria 

                                    Step 3: Select which records to be shared  
                                                  Select the     Field   as    Priority    Operator     as    Equals          Value    as   High 
                                                  ( the value oh high can be obtained by clicking the search icon just next to the field ,search and insert the                                                             value or you can type too).


                                     Step 4: Select the users to share with
                                                      Share with: (droplist and select Roles)      -----Select One---- (droplist and select Training Coordinator)

                                    Step 5: Select the level of access for the users
                                                       Let the access level as Read Only itself.
                                                       and save.


              Our job is not over yet . People getting error messages as SHARING ROLE DOES NOT BEHAVE AS EXPECTED...​  is because you                 have performed well and accurately till step 4 but have not given the  Organization-wide defaults settings as private.
              To change the settings follow the step 5 which is much similar to the step 4.

step 5:     creating the sharing rule--------
          
                security control--->sharing settings
                
               On that page you will see  Manage sharing settings for :   from the droplist select the Project

              After you have done these.....
              
              you'll see Organization-wide defaults   , and click on EDIT.

              and set the Default Internal Access  to  Private . [ this is the thing which most of us miss] ,...because according to the first line of the                    challenge it should ve visible only by the user and upper level of heirarchy.

look at screen Private


User-added image

let me know what changes i need to.. 

thanks


 
Bill KratochvilBill Kratochvil
Thanks CloudyJosh, your suggestion above (copied below for others convenience) did the trick for me!

CloudyJosh
MAKE SURE that you have "Roles" and NOT "Roles and Subordinates" selected in the criteria section, otherwise this will not work! I had everything down correctly except I selected "Roles and Subordinates" then selected "Training Coordinator" and that error kept popping up. Took me two days to figure this out.
Christophe_         LereverendChristophe_ Lereverend
Thanks Rodney Anderson!  Clear instruction, a bit tricky at first then all went good!
Nancy CebaloNancy Cebalo
@Sonam Thank you for some reason I thought it was read/write I have been wondering why it hasnt worked, thank you for pointing that out!!!
Caleb KuesterCaleb Kuester
I kept getting "not as expected" error because when I created the sharing rule, I selected "Role and Subordinates: Training Coordinator" instead of "Role: Training Coordinator." 
Graeme GibsonGraeme Gibson
This is what it says in the task:
"The organization-wide defaults for Project cannot be set to 'Public Read/Write'."
No matter how many times I read it, I did not see the word 'cannot' and only just noticed it after coming here. I set mine org wide sharing for Projects to 'Private' and it worked as soon as the update finished.
Thomas HThomas H
Hello @ bhatt bijal --- great walk - thru    THANKS !!
James France 10James France 10
I have most of this right, but I am still getting the error that the sharing rule did not behave as expected. I created a Training Coordinator role under CEO level, did the other steps and set org-settings for Project to private. Is there anything else I could have missed?
mgiacomgiaco
I am in the same boat as many--Created the Project bit, the Priority bit, went on the create the sharing rules, looped back to make sure all the sharing was off and the defaults were 'private', and I am still getting the dreaded red message of DOOM!  I think I'll just log off and come back later.  This is really frustrating as once this is completed, it's the last segment in the badge. grrrrrrrr.
Saurabh Sood 8Saurabh Sood 8
@shivam sheel great explanation. 
LORI WANGLER 18LORI WANGLER 18
I appreciate the time many of you took to present step-by-step instructions HOWEVER I have double and triple-checked all of the above, compared screen shots, etc, etc. Still getting "the sharing rule did not behave as expected." Anyone else?
Talisha SmithTalisha Smith
I have been getting the same message every time I attempt to complete this unit. My Default Internal and External access are both private, the Grant Access Hierarchies box is checked, I used the magnifying glass to search "High" for the sharing rule, and I shared with the role "Training Coordinator". Can someone please find the error in my attemps? Thanks in advance.User-added imageUser-added image

User-added image
Martin Hurst 9Martin Hurst 9
I was gettng this error "Challenge not yet complete... The sharing rule did not behave as expected.".
I finally figured it out what I was doing wrong, I was creating a Public Group with the Training Coordinator role in it and then creating the Sharing rule using the Public Group but the Trailhead challenge did not like this!!

To get the correct TrailHead challenge answer, instead,
1) I deleted the Public Group with the Training Coordinator role in it.
2) I create the sharing rule using the Training Coordinator role directly in the sharing rule with Read-Only - THAT WORKED!!! The Trailhead challenge accepted this.
 
Simon GrisewoodSimon Grisewood
My Save button on the Sharing Settings doesn't appear to do anything. I can Cancel out of the rule and start again but clicking Save gives no error message, no indication I've clicked on anything. I've double-checked that I've setup the Project object correctly etc. as per the above and other posts but can't find anyone else having had this issue - any ideas?
Hiran Bhatt 6Hiran Bhatt 6

Hello everyone, I've done all the steps above and tripple checked everything yet I'm getting the error message:  Trailhead An object with the API name Project _c does not exist or does not contain the Priority _c picklist field.

User-added image

User-added image

User-added image

User-added image

User-added image

PLEASE HELP ME!!!!

Daniel RobertsDaniel Roberts
In the sharing rule, I was assigning the record sharing to the Training Coordinator under "Roles and Subordinates" When I switched this setting to just "Roles" and selected Training Coordinator it worked. This is pretty bad bug. Took me 30 minutes to catch it. 
Laura Ashcraft 14Laura Ashcraft 14
Like Daniel finally figured out, I had to switch form Roles and Subordinates to just Roles. Worked.
Nikhil SutharNikhil Suthar
https://www.youtube.com/watch?v=XXjl6FKNq0w .....Refer this and you will be able to do it right.
Rock Lee 5Rock Lee 5
travel vairagitravel vairagi

https://es.steinberg.net/forums/memberlist.php?sk=c&sd=a&mode=searchuser&start=128700
https://es.steinberg.net/forums/memberlist.php?sk=c&sd=a&start=128700
https://es.steinberg.net/forums/memberlist.php?sk=d&sd=a&first_char=&mode=searchuser&start=84400
https://es.steinberg.net/forums/memberlist.php?sk=d&sd=a&first_char=&start=82400
https://es.steinberg.net/forums/memberlist.php?sk=d&sd=a&first_char=&start=82500
https://es.steinberg.net/forums/memberlist.php?sk=d&sd=a&first_char=r&mode=searchuser&start=3100
https://es.steinberg.net/forums/memberlist.php?sk=d&sd=a&first_char=r&mode=searchuser&start=3900
https://es.steinberg.net/forums/memberlist.php?sk=d&sd=a&first_char=r&mode=searchuser&start=4700
https://es.steinberg.net/forums/memberlist.php?sk=d&sd=a&first_char=r&start=3900
https://es.steinberg.net/forums/memberlist.php?sk=d&sd=d&first_char=r&mode=searchuser&start=6100
https://es.steinberg.net/forums/memberlist.php?sk=d&sd=d&first_char=r&mode=searchuser&start=6200
https://es.steinberg.net/forums/memberlist.php?sk=d&sd=d&first_char=r&start=5600
https://es.steinberg.net/forums/memberlist.php?sk=d&sd=d&first_char=r&start=6200
https://es.steinberg.net/forums/memberlist.php?sk=d&sd=d&mode=searchuser&start=61100
https://es.steinberg.net/forums/memberlist.php?sk=d&sd=d&start=61800
https://es.steinberg.net/forums/memberlist.php?sk=f&sd=a&first_char=r&mode=searchuser&start=7000
K SanhotraK Sanhotra
@LORI WANGLER 18 yes ..I'm getting and it's driving me insane..time to switch off the machine..Lmao!
Yamini MachhaYamini Machha
Check the BackGround Job  - its on the share setting page, the rule might be in Queue , when its completed , then the error is resolved., wait for it to get completed
Danniel jamesDanniel james
BDCC Global is a leading research company where we list the top DevOps service providers (https://www.bdccglobal.com/top-azure-consultants/) around the globe. Here at BDCC(Best DevOps Consulting Companies) Global, we do a thorough evaluation and analysis of various DevOps consulting companies and based upon certain criteria (primary and secondary research, gathering data from multiple sources), we list them down so that you get to skip the hard work and pick the most suitable DevOps consultants for your business
 
Sophia LaneSophia Lane
Great post your content is highly informative. Thank you so much for sharing!! Please visit our site once. Take advantage of these unbeatable Turkey tourism (https://viztravels.com/turkey-tourism/" style="color:blue; text-decoration:underline) deals! Viz Travels is offering up to 40% off on their 40+ Turkey tour packages from India (https://viztravels.com/turkey-tourism/turkey-tour-packages-from-india/" style="color:blue; text-decoration:underline). Explore the ancient cities, enjoy the breathtaking views, and indulge in the local cuisine with these affordable options.
Don't miss out on this incredible opportunity to travel to Turkey. Book your tour today with Viz Travels (https://viztravels.com/" style="color:blue; text-decoration:underline).