Hello Eric,
Thanks for this information! From the above description, my assumption is
that we are working on a Shared Add In and implement the
Office.ICustomTaskPaneConsumer interface for our add-in class. The dock
panel creating code will be look like the following,
public class Connect : Object, Extensibility.IDTExtensibility2,
ICustomTaskPaneConsumer
...
object missing = Type.Missing;
public Office.CustomTaskPane CTP = null;
public GenericControl gControl = null;
public void CTPFactoryAvailable(Office.ICTPFactory CTPFactoryInst)
{
CTP = CTPFactoryInst.CreateCTP("WorXStudio.GenericControl", "Task Pane
Example", missing);
gControl = (GenericControl)CTP.ContentControl;
CTP.Visible = true;
}
...
Is my understanding right?
If that is the case, the registry keys related to ProgId and GUID are all
necessary. The reason is the CreateCTP¡¯s first parameter need a string
represents ActiveX control¡¯s ProgId. This ActiveX control will be used in
our docked custom task pane. If the registry information are omitted, Word
will not know which ActiveX control is supposed to be presented to the
users on the custom task pane. I think this is just how it works, just a
by designed pattern. What do you think about?
By the way, as far as I test, if we check the option ¡°Register for COM
Interop¡±, then the corresponding registry keys will be imported into the
target machine¡¯s registry automatically during our debugging or deploying
process. So, we do not need to take care of these registry keys. Would you
mind checking the status of the option ¡°Regsiter for COM Interop¡± on
your side? You can view it by clicking the Menu Project->Project
Properties, and in the Project Properties page, we navigate to the Build
tab. Afterwards, we will find the option at the bottom of the page.
Please let me know if this addresses your issue. If you have any future
questions or concerns, please let me know and I know try my best to
provide future help.
Have a nice day!
Best regards,
Ji Zhou (
[email protected], remove ¡®online.¡¯)
Microsoft Online Community Support
Delighting our customers is our #1 priority. We welcome your comments and
suggestions about how we can improve the support we provide to you. Please
feel free to let my manager know what you think of the level of service
provided. You can send feedback directly to my manager at:
(e-mail address removed).
This posting is provided "AS IS" with no warranties, and confers no
rights.
eschneider said:
Hello, Ji
My project was create using references to: C:\Program Files\Microsoft
Visual Studio 9.0\Visual Studio Tools for
Office\PIA\Office11\Extensibility.dll
I'm new to the level of Office development, and inherited this code, so
I'm learn as I go here.
The source of the problem seems to be a docked panel we created which is
shown when the plugin is used. I managed to get things working by
importing some registry keys. The registry keys relate to the progid &
version. Is there a way to deploy with-out the registry imports? Also I'm
not sure what was needed as there were a few in the file. I would like to
import what is actually need or none at all.
In general I would like more info. on deployments for Office addins,
specificly Word.
Thanks,
Eric Schneider
/// <summary>
/// Summary description for GenericControl.
/// </summary>
[System.Runtime.InteropServices.ComVisible(true)]
[GuidAttribute("1B19F6AB-5353-3A62-B776-F0B7600ABDF5"),
ProgId("WorXStudio.GenericControl")]
public class GenericControl : System.Windows.Forms.UserControl
""Ji Zhou [MSFT]"" said:
Hello,
Thanks for using Microsoft Newsgroup Support Service, my name is Ji Zhou
[MSFT] and I will be working on this issue with you.
Using Visual Studio, .NET 2.0 and C#, we can create two kinds of managed
Word Add-in,
1.The Shared Add-in, we create this type Add-in from Other Project
Types->Extensibility node in the New Project dialog.
2.The VSTO Add-in, we create this type Add-in from the C#/VB->Office
Node
in the New Project dialog.
There are many possible issues that can cause the add-in unloaded after
deployment. So, would you mind let us knowing which kind of type Add-in
you
are creating and if it is VSTO, which version of the VSTO you are using.
However, there are some general troubleshooting ways to diagnose the
Add-in
loading issues. I highly recommend the following two blog entry. Hope
they
will help!
http://blogs.msdn.com/vsod/archive/2008/04/22/Troubleshooting-com-add-in-loa
d-failures.aspx
http://blogs.msdn.com/andreww/archive/2008/09/30/addinspy.aspx
Best regards,
Ji Zhou (
[email protected], remove 'online.')
Microsoft Online Community Support
Delighting our customers is our #1 priority. We welcome your comments
and
suggestions about how we can improve the support we provide to you.
Please
feel free to let my manager know what you think of the level of service
provided. You can send feedback directly to my manager at:
(e-mail address removed).
==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/en-us/subscriptions/aa948868.aspx#notifications.
Note: The MSDN Managed Newsgroup support offering is for non-urgent
issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each
follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach
the
most efficient resolution. The offering is not appropriate for
situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are
best
handled working with a dedicated Microsoft Support Engineer by
contacting
Microsoft Customer Support Services (CSS) at
http://support.microsoft.com/select/default.aspx?target=assistance&ln=en-us.
==================================================
This posting is provided "AS IS" with no warranties, and confers no
rights.