Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi
I am trying to debug an automation addin written in VB.NET 2005 for excel 2003 the code is very simple: ============================= Imports XL = Microsoft.Office.Interop.Excel Imports OFC = Microsoft.Office.Interop Imports System Imports System.Runtime.InteropServices Imports Microsoft.Win32 <ClassInterface(ClassInterfaceType.AutoDual), ComVisible(True) _ Public Class JDnumerics Public Function JDmax(ByVal x As Double, ByVal y As Double) If x y Then JDmax = x Else JDmax = y End Function <ComRegisterFunctionAttribute() _ Public Shared Sub RegisterFunction(ByVal type As Type) Registry.ClassesRoot.CreateSubKey(GetSubkeyName(ty pe)) End Sub <ComUnregisterFunctionAttribute() _ Public Shared Sub UnregisterFunction(ByVal type As Type) Registry.ClassesRoot.DeleteSubKey(GetSubkeyName(ty pe), False) End Sub Private Shared Function GetSubkeyName(ByVal type As Type) As String Dim S As New System.Text.StringBuilder() S.Append("CLSID\{") S.Append(type.GUID.ToString().ToUpper()) S.Append("}\Programmable") Return S.ToString() End Function End Class ============================== I can go to Excel - tools - add-in - link to the add-in In excel i can do: "=jdmax(A1,A2)" Everything works well. Now, i add a break point in JDmax() I go in project - properties - debug - start external program: C:\Program Files\Microsoft Office\OFFICE11\EXCEL.EXE I press F5 from VS2005, excel starts I can go to Excel - tools - add-in - link to the add-in I type the function "=jdmax(A1,A2)" I get the result BUT i dont stop in the code I am a bit puzzled by this (especially when I manage to make it work with C#). How do you control which version of the add-in is loaded (debug / release) ? What can it be? Reason for all of this: I am moving all my librairies out of *.XLAs and *.XLLs to VB automation add-in since it is much faster to develop in this environment and that the difference in computational time is marginal at my level Any help would be most welcomed. jerome drean |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Problem deploying an automation addin (VS2005, Windows XP SP1, Excel XP) | Excel Programming | |||
Word 2003 Find/Change Automation from Excel 2003 crashes Excel 200 | Excel Programming | |||
Debug Excel 2003 | Excel Programming | |||
Compiling Excel 2003 application written in VBA 6.0 Code | Excel Programming | |||
Excel 2003 wont recognize UDF written with 2000 | Excel Programming |