Toggle Side Panel

  • Blogs
  • Consultants
    • Salesforce Product Expertise
      • Top Salesforce ConsultantsTop Salesforce Consultants
      • Marketing Cloud ConsultantsMarketing Cloud Consultants
      • Service Cloud ConsultantsService Cloud Consultants
      • Experience Cloud ConsultantsExperience Cloud Consultants
      • Analytics Cloud ConsultantsAnalytics Cloud Consultants
    • Salesforce Industry Expertise
      • Non-Profit Cloud ConsultantsNon-Profit Cloud Consultants
      • Financial Service Cloud ConsultantsFinancial Service Cloud Consultants
      • Health Cloud ConsultantsHealth Cloud Consultants
      • Commerce Cloud ConsultantsCommerce Cloud Consultants
      • Manufacturing Cloud ConsultantsManufacturing Cloud Consultants
    • Salesforce Experts by Location
      • USATop Salesforce Consultants in USA
      • IndiaTop Salesforce Consultants in India
      • AustraliaTop Salesforce Consultants in Australia
      • United KingdomTop Salesforce Consultants in UK
      • CanadaTop Salesforce Consultants in Canada
  • Webinars
  • Contact Us
  • Discussions
More options
    Sign in Sign up
    • Blogs
    • Consultants
      • Salesforce Product Expertise
        • Top Salesforce ConsultantsTop Salesforce Consultants
        • Marketing Cloud ConsultantsMarketing Cloud Consultants
        • Service Cloud ConsultantsService Cloud Consultants
        • Experience Cloud ConsultantsExperience Cloud Consultants
        • Analytics Cloud ConsultantsAnalytics Cloud Consultants
      • Salesforce Industry Expertise
        • Non-Profit Cloud ConsultantsNon-Profit Cloud Consultants
        • Financial Service Cloud ConsultantsFinancial Service Cloud Consultants
        • Health Cloud ConsultantsHealth Cloud Consultants
        • Commerce Cloud ConsultantsCommerce Cloud Consultants
        • Manufacturing Cloud ConsultantsManufacturing Cloud Consultants
      • Salesforce Experts by Location
        • USATop Salesforce Consultants in USA
        • IndiaTop Salesforce Consultants in India
        • AustraliaTop Salesforce Consultants in Australia
        • United KingdomTop Salesforce Consultants in UK
        • CanadaTop Salesforce Consultants in Canada
    • Webinars
    • Contact Us
    • Discussions
    Close search

    Activity › Forums › Salesforce® Discussions › How to restrict the controller action for users which are logged in using “Grant Login Access” in Salesforce?

    Tagged: Apex Class, Apex Controller, Controller Action Methods, Grant Login Access, Salesforce Visualforce Page, System Administrator

    • Salesforce® Discussions

      How to restrict the controller action for users which are logged in using “Grant Login Access” in Salesforce?

      Posted by Aman on September 22, 2018 at 9:39 PM

      A Visualforce page and Controller is created. How to restrict the controller action for users which are logged in using “Grant Login Access” in Salesforce?

      Parul replied 8 years, 1 month ago 3 Members · 2 Replies
      • Apex Class
      • Apex Controller
      • Controller Action Methods
      • Grant Login Access
      • Salesforce Visualforce Page
      • System Administrator
    • 2 Replies
    • shariq

      Member
      September 22, 2018 at 9:39 PM

      When System admin logged in on the behalf of any other user. On upper right corner message is displayed that user is logged-in on behalf of some other user. In Visualforce page we can search for the element with class name present or not? If the element with that Class name exist means logged-in user is not a actual user.

    • [adinserter block='9']
    • Parul

      Member
      September 23, 2018 at 5:30 AM

      There's no supported way to detect that a user is masquerading as another user via Grant Login Access. I have seen some suggestions around cookie sniffing, but as you want to restrict access I'd say that would be a very fragile.

    Log In to reply.

    • Public
    • All Members
    • My Connections
    • Only Me
    • Public
    • All Members
    • My Connections
    • Only Me
    • Public
    • All Members
    • My Connections
    • Only Me

    Popular Salesforce Blogs

    Omni-Channel

    Successful Implementation of Omni-Channel | Salesforce Guide

    Blog in Others, Salesforce Implementation

    In this blog, we are going to discuss Omni-Channel.  Let’s discuss some brief introduction of Omni-Channel.  Omni-channel is one of the important parts of the…

    Chat Buttons, Creation of Queue, Creation of Service Channel, Custom Code, Customer Cases
    Shweta May 21, 2021
    5,641  Views
    Healthcare Industry with Salesforce

    Effective Evolution of Healthcare Industry with Salesforce

    Blog in Salesforce

    Upgrade in the healthcare Industry had, has and will always be the top concern. With time, using technology to enhance the functions of healthcare often…

    Assign Tasks, billing, Budgeted Plan, Build Confidence, Business Analyzes
    Melonleaf Oct 11, 2021
    4,453  Views
    What is the Custom Metadata Type in Salesforce in 2023?

    What is the Custom Metadata Type in Salesforce in 2023?

    Blog in Others

    Custom Metadata Type lets you use records to configure your app without worrying about migrating those records to other organizations.    You can deploy the…

    Apex Transaction, APIs, CheckBox, Custom Metadata, Custom Metadata Records
    Sejal Agrawal Jan 10, 2023
    2,900  Views

    Popular Salesforce Videos

    Revenue Generation Opportunities on AppExchange

    Revenue Generation Opportunities on AppExchange

    Video in Others

    If you're an aspiring entrepreneur or a business professional looking to expand your revenue streams, this video is a must-watch! Watch this extract from our…

    salesforce, AppExchange, Salesforce Video, Video, Business
    Cyntexa Jul 18, 2023
    1,325  Views
    Highlights of the Salesforce Winter '22 Release for Nonprofits

    Highlights of the Salesforce Winter '22 Release for Nonprofits

    Video in Salesforce Stories

    The video includes both Winter ‘22 Salesforce Platform updates and Nonprofit Cloud tools. Chapters: 0:00 General Salesforce.com Platform Updates 8:13 Salesforce.com Release for Fundraising and…

    Salesforce Training, Salesforce Tutorial, salesforce, salesforce platform, Salesforce Video
    Jogender Nov 25, 2021
    2,593  Views
    Build an App Home Lightning Page | Salesforce Lightning Tutorial

    Build an App Home Lightning Page | Salesforce Lightning Tutorial

    Video in Lightning

    Learning Objectives After completing this unit, you’ll be able to: Add components to a Lightning page Configure the properties of a Lightning page and a…

    Salesforce Training, Salesforce Tutorial, Salesforce Lightning, Salesforce Lightning Tutorial, Mobile app
    Prafull May 20, 2021
    1,565  Views
    Footer Forcetalks logo

    support@forcetalks.com

    • twitterx

    Quick Links

    Advertise with Us

    Salesforce® Articles

    Dreamforce 2023

    Top Salesforce® Bloggers 2023

    Top Salesforce Consultants

    Get Listed

    Company

    Contact Us

    About Us

    Privacy Policy

    Terms & Conditions

    InsightHub

    Salesforce Blogs

    Salesforce Videos

    Salesforce Groups

    Salesforce Jobs

    © 2026 - Forcetalks ● All Rights Reserved

    Salesforce® is a trademark of Salesforce® Inc. No claim is made to the exclusive right to use “Salesforce”. Any services offered within the Forcetalks website/app are not sponsored or endorsed by Salesforce®.

    We use cookies to enhance your browsing experience. Please see our privacy policy if you'd like more information on our use of cookies.