vsto

Displaying WPF-“NotifyIcon” on a separate thread

萝らか妹 提交于 2020-01-04 02:03:08
问题 I am currently working on an office add-in and I need to show a notification dialog that displays progress, I'm using Philipp Sumi's wpf-notifyicon. I need to display the notifyicon from a separate thread as I have a lot of code that already executes on the main thread, this causes the wpf-notifyicon to block and wait because the messages in the windows message queue are not being processed. I know that I should rather execute this time consuming code on a separate thread, and display the

How to add a group to multiple built-in Ribbon tabs (vsto)?

风流意气都作罢 提交于 2020-01-03 10:44:10
问题 This is VS2010 + Office 2010 add-in. All I want is to add a button ( or button group ) to multiple built-in tabs. For example, my buttons should be available in both New Mail Message Ribbon and in New Appointment Ribbon . I have tried adding a new tab ( in the Visual Designer ) but that doesn't seem to work. The button group appears on the New Mail Message tab, but not on the Appointment tab. BTW, I'm using the following IDs: TabNewMailMessage and TabAppointment . 回答1: For anyone else pulling

Ribbon tab exists even after uninstalling PowerPoint Add-in

∥☆過路亽.° 提交于 2020-01-03 05:57:13
问题 I have created an application level Add-in for PowerPoint 2010/2013 using C# VSTO. The add-in is installed from msi installer file. The problem is that after I uninstall the add-in from the control panel and open a new PowerPoint presentation, the ribbon tab is still visible with all the functionalities correctly working. To remove the tab I have to do either of the following two things: Remove the add-in from the COM Add-ins list from the PowerPoint Developer tab. End the running instance of

VSTO with Windows Form and Worker Threads

浪尽此生 提交于 2020-01-03 05:04:45
问题 I have an Office addin (Outlook if it makes a difference) created with VSTO. The addin creates a Windows Form at startup. My Form creates several threads. I'm looking for either concrete guidance or peoples' experiences with what safely works for the following situations: 1.) A thread created by the Form needs to access the Office object model (Globals.ThisAddIn.Application) 2.) A thread created by the Form does not need to access the Office object model, but does need to update a control on

How can I find out about undocumented .NET / COM library functions?

我们两清 提交于 2020-01-02 11:05:14
问题 How can I find out the properties and methods of COM objects returned from some .NET functions, which do not appear to be documented? In the particular example I'm looking at, I'm inserting a picture into Excel using a function like: Set NewPic = ActiveSheet.Pictures.Insert(FileName) (See the SO post on this here.) However, the MSDN documentation for this function only says that Worksheet.Pictures returns an Object, and when I put a watch on the variable during debugging its type is System._

Form.Show(IWin32Window) method in Excel VSTO causing ThreadAbortException on application close

拥有回忆 提交于 2020-01-02 09:24:32
问题 I have an excel add-in and i have a form that i would like to be front of excel window. I use NativeWindow for this purpose on excel ribbon menu button like this: public partial class MyRibbonMenu { public List<Form> Forms = new List<Form>(); private void button1_Click(object sender, RibbonControlEventArgs e) { // initialize form Form frm = new Form(); frm.Text = "Test Form"; Forms.Add(frm); // create the native window handle NativeWindow nw = new NativeWindow(); IntPtr iptr = new IntPtr

Form.Show(IWin32Window) method in Excel VSTO causing ThreadAbortException on application close

两盒软妹~` 提交于 2020-01-02 09:24:22
问题 I have an excel add-in and i have a form that i would like to be front of excel window. I use NativeWindow for this purpose on excel ribbon menu button like this: public partial class MyRibbonMenu { public List<Form> Forms = new List<Form>(); private void button1_Click(object sender, RibbonControlEventArgs e) { // initialize form Form frm = new Form(); frm.Text = "Test Form"; Forms.Add(frm); // create the native window handle NativeWindow nw = new NativeWindow(); IntPtr iptr = new IntPtr

Adding a section to the To-Do bar in Outlook 2007/2010?

与世无争的帅哥 提交于 2020-01-02 07:59:51
问题 I would like to add a new section to the To-Do Bar in Outlook 2010 (or 2007). I found some code to create a new collapsible task pane and someone claiming you can't modify the To-Do bar, but I also found a product called Add-In Express that claims it can do it (although at $349 it's not worth it for a one-off project). Is is possible to do that? 回答1: After some research (and after having seen the product documentation of Add-in Express), I figured that it is possible to customize the To-Do

VSTO Excel Add-In with Visual Studio Express

你。 提交于 2020-01-02 06:06:21
问题 I want to create an add-in (a ribbon precisely) for MS Excel by using Visual Studio C# 2010 Express. I have searched and read about it here and here and somewhere else. However, when I want to create a new project I don't see any template as described, I don't see even the Office tab. Is it because I am using the Express edition? I think it shouldn't be. Because in this official comparison they say all editions are capable of office development. What can I do to develop this add-in? 回答1:

VSTO project with multiple versions of office installed

。_饼干妹妹 提交于 2020-01-02 04:42:28
问题 I currently have office 2010 installed, and am trying to assist a coworker who's still using 2007 with VSTO solution. This is turning into a mess since my copy of visual studio thrashes the project files updating them to point to the O2010 dlls. If I were to install office 2007 beside 2010 would I be able to open the solution without the upgrade wizard mangling everything, or are my only options making significant architectural changes to the solution or reverting to O2007 until my employer