Setting permission on a GUI

Hi,
I have a question that have bothered me for a few day. I'm developing a GUI and would like to set different permissions on the various parts of the GUI.
When the GUI is loaded these permissions are read and components who should not be shown will not be created, is there a smart way to do this with the API?
Solving this with if(buildThis()) { //... } is not nice, have you got any ideas?
Thanx
MD

This is something you will have to handle yourself. Its really not that complex, and if a particular user is not going to see the objects, ever, then theres no point creating them and just setting them invisible. That is a waste of memory. But if you don't ahve the permission level at the beginning, then you'll have to do the setVisible version.
static final int ADMINISTRATOR = 5;
int permissionLevel = getPermissioneLevel(user);
if (permissionLevel > ADMINISTRATOR) {
buildAdministratorTools();
etc.. you probably already know all this, but the quick answer is no, the API can't do this for you.

Similar Messages

  • Error: The user does not exist or is not unique - when setting permission programmatically

    Hi,
    I am custom Sequential workflow in which I am breaking the permission and setting permission to list item.
    I have used the below code for setting Permission:
    SPRoleDefinition oSPRoleDefinition = oSPWeb.RoleDefinitions["RoleName"];
    //Grant permission to Manager
    SPRoleAssignment oSPRoleAssignmentManager = new SPRoleAssignment(strManagerLanID, strManagerEmail, "", "");
    oSPRoleAssignmentManager.RoleDefinitionBindings.Add(oSPRoleDefinition);
    CurrentListItem.RoleAssignments.Add(oSPRoleAssignmentManager);
    I am getting the error as :
    Error: The user does not exist or is not unique.
    How to fix this?
    Thanks

    I think you misunderstood the solution proposed by frederic, what he is suggesting is that the error doesn't come from your code but from the user account
    have you tried with another account ? (maybe the one you are using to log to your environment)
    With this information, it will help us to know if the problem comes from your code or from the user account
    Best regards, Christopher.
    Blog |
    Mail
    Please remember to click "Mark As Answer" if a post solves your problem or
    "Vote As Helpful" if it was useful.
    Why mark as answer?

  • Need to add Polish option to character set menu in SAP Gui

    Basis Gurus,
    We have installed the Polish language on our unicode R/3 system and now
    need to add it as a character set option in the Gui menu.
    Menu Path:
    Customize Local Layout --> Character Set --> (Missing Option for Polish)
    I have searched OSS and online resources and have not found out how to
    add an entry in this menu.
    I did alter the file frontEN.txt in which the menu entries are built,
    but did this not add the entry.
    Can you please advise on the procedure to add this entry. Our
    developers need it to view special Polish characters in their SapScript.
    Thanks,
    Jeff Martens

    Deepak,
    Thanks for the reply.  I've read that document before, it's helpful with some of the I18N settings, but does not explain how to add a language to the "character set" menu.
    Does anyone know if this is possible?
    Thanks,
    Jeff

  • Any Setting/Permission for GRPO to Restrict Update

    Dear all
       Is there any setting for Restrict permission for update GRN before add,for example user want add GRN only based on Purchase order (Quantity,price,tax,item...)he should edit the GRN,he can only ADD

    hi,
    Make a seperate approval procedure for the GRPO. then he(End User) can add GRPO. but the manager can reject are approve the docuemtns like wise you can restrict the user.
    it means it is draft mode this will not create the journal entry. once the document gets approve then it will create teh journal and inventory gets updated.
    Regards
    Chidambaram

  • Client setting permission

    I created a client setting from CAS for one of primary site, but user from that site with member of  "Operations Administrators" security roles is not able to view/modify the property of this client setting on the Primary
    Site server console. When I check the client setting, the security group that user belong to has full control permission to the client setting? Can I know where is wrong? DB permission?
    Jason

    I'm not sure that I fully understand your question...
    If you want to delegate the control of a custom Client Setting to a specific administrator, you will need to do it via RBA.
    Create/use a custom scope (not Default) and assign the scope to the custom client setting. Then assign the Security Role (e.g. "Operations Administrators") to the admin user and restrict it to the scope.This is so that the admin only has permissions on client
    setting(s) that are linked to the select scope.
    more on RBA:
    http://blogs.technet.com/b/configmgrteam/archive/2011/09/23/introducing-role-based-administration-in-system-center-2012-configuration-manager.aspx
    If the settings "All instances of the objects that are related to the assigned security roles" is working, it could be that you did not create a scope to assign when using another option (e.g. "Only the instances of objects that are assigned to the scpecified
    security scopes and collections" or "Associate assigned security roles with specific security scopes and collections").

  • Set permission level for views

    I have a list which has some views.
    I am showing one of the view in a list view webpart on a wiki page. I dont want the users to view the other views on this list apart from the view set up on the webpart.
    How do I set the permission levels to achieve the same.
    Many thanks in advance.

    The views can either be personal or public. If the view is public it will be visible to users. You may either need to delete the view or create a new personal view similar to the public view before deleting it.
    Blog | SharePoint Learnings CodePlex Tools |
    Export Version History To Excel |
    Autocomplete Lookup Field

  • Setting permission using java code

    hi all i am writing a code to upload file from the users to the server. i can write the files to the server but after that i cannot change it's permission to read and execute by all. only the server can read and execute it. i talked about this problem with the systems admin and he suggested i include some sort of java code to set the permission to everyone. can any one suggest me what sort of code is helpful in this regard? i am absolutely helpless about this. any help will be appreciated.

    Depends on what you mean. If you want to programatically include/exclude a folder in a, say, File Open dialog that your program displays, then yes, absolutely. If you're asking whether can set an operating system security flag on a folder, then the answer is probably not (at least not without resorting to native code), and it will almost certainly not be portable across different operating systems.

  • How to set permission to export PDF?

    We developed plugin based on Acrobat XI SDK to save PDF as TIFF using example of AVConversionEnumFromPDFConverters
    How can I set PDPermReqObjDoc document permission PDPermReqOprExport to "yes" to always allow conversion?

    Our plugin converts PDF to TIFF automatically. How can we set option not to show pop-up dialog boxes, i.e. not to interact with user?
    So far, we set  kAVConversionNoFlags and for AVConversionConvertFromPDFWithHandler setting use:
         ASCab settings = ASCabNew();
        ASCabPutInt( settings, kExtractImgCmdKeyResolution, kImgResolutionAuto );
        ASCabPutInt( settings, kExtractImgCmdKeyColorSpace, kColorSpaceMonochrome );
        ASCabPutInt( settings, kExtractImgCmdKeyConvFormat, kImgConversionFormatTiff );
        ASCabPutInt( settings, kExtractImgCmdKeyConfigured, true );
        ASCabPutInt( settings, kExtractTiffCmdKeyMonoCompression, kTiffCompressionCCITT_G4 );
        ASCabPutInt( settings, kInsertPagesCmdKeyInsertBefore, kAVPosRelativeToFirst );

  • How to set permission levels per site collection

    Hello,
    A site collection would have 700 sites , with the same (new) permission levels. Is there a way (apart from programming) to copy these permission levels?
    Thank you.
    Christos

    Hello,
    Check this link
    http://social.technet.microsoft.com/Forums/en-US/bdb82f15-6d9c-47b3-b511-f8e019347895/how-to-set-permissions-to-list-item-sharepoint-programmatically
    Thanks!

  • Unable to set permission on KM Content

    I was trying to change the permissions on my CM Repository folders as Everyone has Full Access to all content.
    I go to Content Administration => KM Content then click on the Context Menu and select Details.  In the new window, I select Settings => Permissions.
    I set the Permissions for the user Everyone to Read, click save and get a message "Permissions have been saved", however it still shows "Full Control".
    Portal Netweaver 7.4 SP 05
    CM Repository - Persistence Mode DB
    WebDav URL: http://*************/irj/go/km/docs/documents
    My user is one of the folder owners, is Content Admin and Super Admin
    Any idea why I could be having this issue?

    Logged an OSS call and the issue was related to duplicate records in the KMC_ACL_SUPP_PERM .
    You can refer to the following:
    KBA 1844853
    https://websmp230.sap-ag.de/sap(bD1lbiZjPTAwMQ==)/bc/bsp/sno/ui_entry/entry.htm?param=69765F6D6F64653D3030312669765F7361706E6F7465735F6E756D6265723D3138343438353326

  • How do i set permission for mac book air to use drop box?

    I am trying to share photos with my son's mac book air. Each time he tries to access my Mac it says he doesnt have permission to access the Dropbox. I cant find out how to change this.
    His Mac book air has Air drop but it seems that I don't have this facility.
    I have tried exporting files to Mac book air and it looks like they have gone through but can't find them!
    It is exasperating- I thought sharing files would be easy- have no hard wiring to do it with so does anyone know what I am doing wrong?
    Any help appreciated!!!

    If your MBP has Lion installed then you have iCloud by updating to 10.7.2.
    If you have a 2011 MBP then Lion should be pre-installed. If it is not then you can purchase and download it via the App Store if you have 10.6.6 or later installed. If you have older PPC-only applications such as Office 2004, then they will have to be upgraded because PPC-only applications will not run in Lion.
    You can, however, add a second partition to your hard drive and install Lion on that partition. In this way you can keep your older applications and boot into Snow Leopard when you need to use them.

  • Set Permission on RemoteApp 2012 R2

    How can I set 2012 R2 RemoteApp to allow certain users\groups accessing certain application and not other application without creating a new COllection

    Hi Wen,
    Thank you for posting in Windows Server forum.
    In addition to Razwer comment, please check below articles.
    Introducing RemoteApp User Assignment (For reference)
    http://blogs.msdn.com/b/rds/archive/2009/06/12/introducing-remoteapp-user-assignment.aspx
    Distribution of Remote Apps and desktops in Windows Server 2012
    http://www.virtualizationadmin.com/articles-tutorials/vdi-articles/general/distribution-of-remote-apps-and-desktops-in-windows-server-2012.html
    Hope it helps!
    Thanks.
    Dharmesh Solanki

  • Setting Permission

    A complete novice to mac
    I can't repair permissions on any of my other hdd apart from main hdd.
    If I get info on the hdd, unlock using the padlock, click on the plus to add myself to the list - window closes!

    Niel,
    read this two minutes after posting - thanks.
    In researching this issue I have read substantial post relating to permission issues on folders etc, more specific relating to an unknown user - I have followed advice and sort this out for the main hdd, but how does one remove the unknown user from other volumes.

  • Keep getting error:16 message after setting permission on my hard drive

    I was having an issue with my Mac asking me for a password every time i threw away something.  I went here http://www.fixkb.com/2012/09/mac-asking-for-password-when-moving-files-to-trash.html and did both steps.  Now all my adobe programs wont open and i get a error:16 message
    Please uninstall and reinstall the product.
    If this problem still occurs, please contact Adobe technical support for help, and mention the error code shown at the bottom of this screen.
    Error: 16
    http://www.adobe.com/support/
    HELP!!

    Check if you have the Adobe PCD and SLStore folder available under /Library/Application Support/Adobe. Is so, then follow the solutions mentioned unde the below article.
    http://helpx.adobe.com/x-productkb/policy-pricing/configuration-error-cs5.html
    If you donot see those folders, you might have accidently deleted them. Re-install will be the best option.

  • How to set item level permission for list item in SharePoint 2013

    Hi we had a custom List "ABC".
    List had 2 columns:
    Project Name: (P1, P2, P3, P4, P5, P6)
    Project Leads: (PL1, PL2, PL3, PL4, PL5, PL6).
    All project Leads can have permission to edit only their Project (P1, P2, P3) like
    PL1 can edit P1
    PL2 Can edit P2.....
    But my Question is how to restrict PL2 cannot have permission to edit P1
    is it possible to set permission for this through OOTB in SharePoint 2013.
    Any help will be appreciated......

    Hi
    check this similar post
    http://social.technet.microsoft.com/Forums/ro-RO/e1ea3655-0c6f-4b3d-a336-c42e8eb54c09/rights-to-edit-own-items-for-list-residing-on-publishing-site?forum=sharepointdevelopmentprevious
    Romeo Donca, Orange Romania (MCSE, MCITP, CCNA) Please Mark As Answer if my post solves your problem or Vote As Helpful if the post has been helpful for you.

Maybe you are looking for

  • Script to calculate space usage at the database level.

    Hi, Can someone provide me a script to calculate the Total space, Used space and Free space for all tablespaces within a database?? I have been trying to use the below combinations in my queries and both provide different results.. 1) dba_data_files

  • Purple line after installing...

    I just recently installed the new update to iTunes and Quicktime. As soon as my computer restarted a single purple vertical line of pixels appeared on my screen, at first it would disappear and appear at random, but now it is just stuck there. It is

  • Can't Delete 2 E-mails in my Inbox

    I was trying to fix an e-mail problem and I went to move my inbox and it disappeared and recreated a new one but the two old e-mails still show up and I cant delete them. I can't find the other inbox all I can find is the new one that is holding the

  • Maintaining multiple ship to party address in ECC 6.0

    Hi Guys, Could you please let me know, how we can multiple ship to party address for a customer in ECC 6.0? Thanks, Kam.

  • Close Internet Explorer Prompt

    We all know how to end IE with the ctrl+alt+delete. The prompt comes up no matter what I do. I can't uninstall or complete my install. I get error messages every two seconds and my computer is a dog. Adobe, there must be a solution, everyone asks the