In some circumstances I am showing a message box, exactly when my WPF user control which is embedded within a custom task pane gets resized (its height). The WPF user control triggers the resize event when the custom task pane (located at top) gets resized. The message box is a custom WPF user control that is embedded within an ElementHost.Through the elementhost I can display it in the Outlook Add-in side (which in fact it is a winforms app).
I have tried to approaches to show the custom WPF message box:
Showing it using the main UI thread
Showing it using a System.Windows.Forms.Timer
If I use first approach, the custom WPF message box is correctly rendered and shown but it is not centered correctly in the Outlook workspace. However, if I use the second approach, the custom WPF message box is correctly centered in the Outlook main window but then it is not correctly rendered and shown at all, I mean, the bottom border of the message box is not drawn.
The border in the WPF user control (message box) is as below:
<Border BorderBrush="#BEBEBE"
BorderThickness="1,0,1,1">
So why I am getting these weird behaviors? I need the message box to be centered in the Outlook window and shown/drawn correctly. Some things work in the first approach and others in the second one. How can I do this?
Related
I want to create my custom toolbar at the top for explorer and inspector window. I want to make it ALWAYS visible. So which is the best approach, to use a custom task pane or a form region? Which best? What are the advantages and disavantages for each one?
The toolbar should be able to contain buttons, text fields, checkboxes, drop-down lists, etc.
There is no layout at the top for Outlook form regions.
Custom task panes is an Office-wide feature available in all Office applications (most of them to be precise). When you create a custom task pane for Outlook, the custom task pane is associated with a specific Explorer or Inspector window. Explorers are windows that display the contents of a folder, and Inspectors are windows that display an item such as an email message or a task.
Form regions are custom pieces of user interface that can be used to customize a standard form. They are not designed to customize the Explorer window, they are designed for item's forms. And created and designed only for Outlook.
You may also consider using Advanced Outlook view and form regions. They allows placing a form region at the top.
Using Ribbon Workbench 2016 (3.1.177.1).
I'm fairly new to this, but I've successfully created a button for the unified interface which performs as expected.
However, the icon I've selected is white on a transparent background - as I believe it should be.
This works fine for the UI on desktop, which renders the command bar with a blue background.
However, when used on a phone, all commands appear in the "More Commands" flyout with a white background so the icon is not visible, as it is white on white.
I had a look at the display/enable rules, and couldn't see an appropriate option (CommandClientTypeRule only offers 'Modern, 'Refresh' and 'Legacy').
Is there a way for me to specify an image to use in the Modern interface in Phone layout? Or a way to show a different button if it is in the context of a flyout?
Thanks
Yes, the unified interface uses SVG image for Ribbon icons.
It can be set under ModernImage option in Ribbon Workbench after uploading in Dynamics CRM web resource.
I create new PowerPoint Content web add-in.
I want use add-in behind a text. For this I make for add-in "Send to back" and for text make "Bring to front". But in slide an add-in stay always on top see attached image.
Notice: in preview panel arrange works but in slide not. In slide show mode (F5) also not works.
PowerPoint version:
That's a known issue. Content Add-ins (Agaves) do not participate in the Z order within a slide.
I'm developing for Windows 8 (WInRT) and have problem with settings charm. Settings popup is based on Microsoft SDK settings charm. Settings panel is Popup. Content is wrapped by ScrollViewer -> Grid -> StackPanel. In StackPanel I have input fields. when I trying to fill last of them on screen keyboard overlaying it and I cant see field and cant scroll to it. Is there any way to see it and to scroll to it automatically?
Seems like the popups on Windows 8 suffer from the same problem as they did on Windows Phone in that when you put a TextBox on one of them - it does not get pushed up together with all the other content as it does when it is not in a popup.
My solution to that would be to not use popup for input fields and instead go for a layout that you can manage yourself.
By default the app has a Frame control at its visual root. You can modify it for example by putting your own UserControl in there (I usually call it AppShell) which has the Frame used by all pages, you can have a layer for popups, log in screens, the extended splash screen etc.
To solve your problem you would need to put your charm's UI inside of such layer instead of in a popup. Then the build-in mechanism that pushes all the UI up when the on-screen keyboard would otherwise obstruct the view of your TextBox should just start working again.
*EDIT
A simpler solution might be to make sure your settings panel popup is parented in your visual tree - e.g. by adding it as a child element to a root grid of your app or page. It turns out that in that case its content does get pushed up when the OSK shows up.
Take a look at this post
It's a popup wrapper (turns user controls into popups) that takes care of the keyboard appearing and adjusts the size of the popup (and thus the user control) accordingly.
I have an Outlook Add-in created with VSTO. Using the Ribbon Designer I have created a tab with three buttons on it. (Environment: Outlook 2010, .NET 4.0, VSTO latest runtime)
When one of the buttons is pressed a modeless dialog is opened. As long as the user is working on this dialog I do not want him to be able to press the button again. So basically I want to gray out the button till the dialog is closed. How can I do this?
For whatever reason, in the button click handler, if I do this.button1.enabled = false; it is just not working. Am I missing something about the way ribbons work.
Thanks
You need to re-render the control using IRibbonUI.InvalidateControl(controlID) or IRibbonUI.Invalidate(). See MDSN on how to dynamically update the Fluent UI for reference. This is done for performance reasons so that you can change all your Fluent UI settings and then re-render all control changes at once. However, if you are only changing one UI element (as you indicate) this can seem confusing and unnecessary.