Developer Portal Community

    cancel
    Showing results for 
    Search instead for 
    Did you mean: 
    SOLVED

    Is there a way to see all the functions/buttons assigned to a given user right?

    Is there a way to see all the functions/buttons assigned to a given user right?

    Matyas_Kolcza
    Established Member

    Hi,

    I am wondering if there is a way to see all the functions/buttons assigned to a given user right?

    For example I would like to know which functions/buttons EditData104 is assigned to. For this I have to click into each HMI view and check one by one every button? Is there a simpler solution?

    Thanks!

    1 REPLY 1

    nexidator
    Community Moderator
    Community Moderator

    There are two ways of referencing user rights:

    • Directly in the data of CpStudio, e.g. at manual functions
    • In the View designer at the Authorization properties

    It is easy to find the usages of the first kind:

    • In CpStudio, open View --> Data by category --> User management
    • Select the right
    • Press F11
      • If nothing happens, the right is not referenced anywhere.
      • If it is referenced in exactly one place, CpStudio will navigate there directly.
      • If there is more than one usage, a dialog will pop up showing all usages

    The usages in the HMI views cannot be found that easily, but it should work this way:

    • Search all sfc files in the subfolders of Station\Hmi\SmartForms for Right="EditData104" (e.g. using notepad++, Find in files...)
    • Unfortunately, it is not easy to find out which object the views belong to (unless the view name gives you a hint), because the containing folder does not have a readable name but a GUID instead. But you can find out what object the GUID corresponds with.
    • Open the file Station\Hmi\config.xml with a text editor and look for the folder name (the GUID). You should find a line starting with <Unit having the XML attribute sfcPath="SmartForms\<YourFolderNameGuid>". The same line also tells you the name of the object.
    • Now you should be able to identify and open the view in CpStudio.
    • Finding the control that the right is assigned to: Some lines above the place where you found the right in the sfc file, there is a node like <Mod_Button wfml:ID="Mod_Button1". Mod_Button1 is the name of the button.
    • On top of the Smart Properties in CpStudio, there is a dropdown list where you can find and select all the controls by their name.

     

    Besides, I have one small hint: I would recommend to use separate rights for different use-cases. The EditData rights are meant for the data editor. Of course, it works to use the same rights somewhere else. But if you create your own rights for project-specific use-cases, you have the chance to give them a meaningful name and text, telling the user admin what features he is actually enabling by granting a right.

    Icon--AD-black-48x48Icon--address-consumer-data-black-48x48Icon--appointment-black-48x48Icon--back-left-black-48x48Icon--calendar-black-48x48Icon--center-alignedIcon--Checkbox-checkIcon--clock-black-48x48Icon--close-black-48x48Icon--compare-black-48x48Icon--confirmation-black-48x48Icon--dealer-details-black-48x48Icon--delete-black-48x48Icon--delivery-black-48x48Icon--down-black-48x48Icon--download-black-48x48Ic-OverlayAlertIcon--externallink-black-48x48Icon-Filledforward-right_adjustedIcon--grid-view-black-48x48IC_gd_Check-Circle170821_Icons_Community170823_Bosch_Icons170823_Bosch_Icons170821_Icons_CommunityIC-logout170821_Icons_Community170825_Bosch_Icons170821_Icons_CommunityIC-shopping-cart2170821_Icons_CommunityIC-upIC_UserIcon--imageIcon--info-i-black-48x48Icon--left-alignedIcon--Less-minimize-black-48x48Icon-FilledIcon--List-Check-grennIcon--List-Check-blackIcon--List-Cross-blackIcon--list-view-mobile-black-48x48Icon--list-view-black-48x48Icon--More-Maximize-black-48x48Icon--my-product-black-48x48Icon--newsletter-black-48x48Icon--payment-black-48x48Icon--print-black-48x48Icon--promotion-black-48x48Icon--registration-black-48x48Icon--Reset-black-48x48Icon--right-alignedshare-circle1Icon--share-black-48x48Icon--shopping-bag-black-48x48Icon-shopping-cartIcon--start-play-black-48x48Icon--store-locator-black-48x48Ic-OverlayAlertIcon--summary-black-48x48tumblrIcon-FilledvineIc-OverlayAlertwhishlist