i cant display a new menu in revit via API im following the walktrough 2 in the revit api developer guide, I modified the revit.ini file like the example that comes and also the code but i cant display it i dont know the reason,
i atach the revit.ini file modification.
Code:
[ExternalApplications]
EACount = 1
EAClassName1 = AddMenu.CsAddMenu
EAAssembly1 = C:\Users\Workstation1\Documents\Visual Studio 2008\Projects\AddMenu\AddMenu\bin\Debug\AddMenu.dll
and the code in c#:
using System;
using System.Windows.Forms;
using Autodesk.Revit;
public class CsAddMenu: IExternalApplication
{
public IExternalApplication.Result OnShutdown(ControlledApplication application)
{
return IExternalApplication.Result.Succeeded;
}
public IExternalApplication.Result OnStartup(ControlledApplication application)
{
Autodesk.Revit.MenuItem menuItem = application.CreateTopMenu("NewMenuItem");
//Create a menu iterm in the top menu “NewMenuItem”, click it,
//the add-in application “HelloWorld” will be triggered.
menuItem.Append(Autodesk.Revit.MenuItem.MenuType.BasicMenu, "HelloWorld",
@"C:\Users\Workstation1\Documents\Visual Studio 2008 @\Projects\HelloWorld\HelloWorld\bin\Debug\HelloWorld.dll ", "HelloWorld.CsHelloWorld ");
return IExternalApplication.Result.Succeeded;
}
}
i built the HelloWorld.dll lib and the AddMenu.dll file but i cant display the new menu so i think the problem is in the .ini file but i dont know i will thank any help!