Hide field based on user role?

Hi there! I’ve got a page with various pricing values tied to different discount bands, and I’ve assigned user roles for each band.

I’ve currently set all price discounts to display on my page view. Is there a way to hide fields depending on the user’s role, so they only see the relevant discount band?


Hi @marketing1,

Display rules are available to use in form views, details views, and grid views. You can check out our article here to learn more: Using Display Rules.

Please don’t hesitate to reach out to our support team for assistance with this. They will be very happy to help and will be able to take a look at your app to give you a more tailored response on how to accomplish this with your current page/view setup. You can do so by submitting a ticket here: Contact Knack Support & Learn More.

Happy Knack building! :slight_smile:

The short answer is No, you can’t. The only way to do it is to add a duplicate view on the same page then set Page View Rules to Hide/Show specific views based on the user roles. It’s super cumbersome and annoying and hopefully the folks at Knack are working on enabling fields to be shown or hidden based on user roles. If they can do that it would save a ton of time in setting up duplicate information for admin versus client.

Thanks Matthew, that’s a shame. It would be a powerful feature and hopefully something that is being worked on!