Hiding a ribbon button when specific Dynamics CRM Web Resource is in context - ribbon

Like most of dynamics crm programmers know, we can add "web resources that are not associated with any entity" to the sitemap. If such a customization is made, when user clicks that link, web resource will be opened and the buttons in the application ribbon will be added to the ribbon section of the dynamics crm.
What I am wondering is if there is any way I can hide this global buttons that are in the application ribbon based on the web resource on the page.
Let's say I added more than one web resources to my sitemap, namely a.htm and b.htm. Let's say I have a custom button named x in the application ribbon. Right now x is displayed both for a.htm and b.htm, but in reality I would like to hide the button when user clicks on b.htm from the sitemap.
Is there a way to accomplish that?

You could use the following (unsupported) code to hide the Ribbon button (the 'Run Workflow' button in this example):
var btnRunWorklfow=top.document.getElementById("account|NoRelationship|Form|Mscrm.Form.account.RunWorkflow-Large");
btnRunWorklfow.style.display='none';
You can also use ribbon editor available in codeplex to disable your button based on your javascript.
Refer to: http://crmvisualribbonedit.codeplex.com/

I figured there is no supported way of doing this.

Related

How to make a Pop-up table appear in Workshop Palantir Foundry?

I want a pop up to appear showing some stats on the load of a module in Workshop, Palantir. Please help how can i achieve this?
Workshop just released a new feature that allows you to set a “modal” layout component. Whereas previously you could only add a “drawer” that button now offers to add an “overlay” and in the config you can choose either the drawer or modal layout.
From there you can add widgets and otherwise build the content and then trigger it to open and close with Events, just like the drawer.

Remove / hide “Action” button from Slate Homepage

We’re deploying a new slate landing page on our stack. There’s an action button that seems to be showing up for everyone in the top right of the page. Any way to either get rid of it or only show it for users of a particular given group?
Thanks!
You can hide the action button with a snippet of document CSS.
The easiest way to figure this out is to right-click -> inspect on the element and find the top-level HTML element for the button - in this case it's the sl-app-view-actions element.
In the Styles tab in your Slate document, simply add:
sl-app-view-actions { display: none }
Note that with the 'Actions' dropdown hidden, you'll need to manually navigate to the /edit URL to access edit mode or access edit mode through the actions on the Compass resource.
Your users will also no longer have access to the "Get Shareable View" or "View Source Datasets" actions.

Chrome app navigate htmls without creating windows

I'm creating a chrome packaged app, and I need to navigate my htmls without creating a lot of windows, like, if the user click one button, it opens the html in the same window the user are.
Is it even possible? If not, is there a way to make windows modal? So the user can't focus another window without closing the current?
Packaged apps intentionally do not support navigation. Apps are not in a browser, there is no concept of forward, back, or reload. Applications which do require the concept of navigation, or modal dialogs, should use a user interface framework that supports that functionality. In fundamentals, you can navigate by manipulating the DOM or by using CSS to animate and control visibility of components of your app.
The page you want to navigate to can be opened in a new window, then the previous page can be closed.
function navigateToLink (link) {
var current = chrome.app.window.current();
chrome.app.window.create(link);
current.close();
}

Hiding Edit menu item in Access

How can you hide the top menu item labeled "Edit" inside an Acccess application?
Thanks
Don
You should be able to define a custom toolbar to be used by your application (pre-2007), one that omits the Edit option. In 2007, you would do this by making a custom ribbon for your application, again - omitting the Edit option

Change MS Office Button Icon

Has anyone found a way to change the icon displayed in the Office Button in A2007?
Having converted an MS Access 2003 app to 2007, it's very annoying that my app is now displayed as an MS Office app instead!
You can certainly hide all of the ribbon and the office button with one line of VBA code in your startup. You can use:
DoCmd.ShowToolbar "Ribbon", acToolbarNo
The above will hide the office button the QAT and the ribbon.
edit:
You were asking how to hide everything. It is just a simple great one of code that will accomplish this for you.
If you are looking to build a custom UI, then you are free to do so. About the only limitation of a custom ribbon is you HAVE to have file button (but, I think every program I installed for 15+ years had a file option anyway).
So, you are most free to customize what that file button shows. You question simply asked how to hide everything and the above does that with ease.
So, if you do want a ribbon, then your custom ribbon can specify startfromScratch = true, then the only UI options you add to your ribbon is what the user will see.
However, a custom ribbon will always have the file button (or what we often call pizza button and that simply part of the ribbon).
You can also consider using menu bars and not showing the pizza button, but 2007 does not have a built in menu bar builder like previous versions did. This abilty to show only a custom menu bar is outlined here:
http://www.accessribbon.de/en/index.php?FAQ:7