Hello together,
is it possible to add a textbox to the ribbons in Inventor 2013?
Thanks
Georg
Solved! Go to Solution.
Solved by Ralf_Krieg. Go to Solution.
Hello
Afaik no, but take a look at dockable windows, where you can display similar everything.
The previous answer is correct. You cannot create a text box in the ribbon. You can create a text box in a mini toolbar. This is what many of the commands now use to replace dialogs, like the extrude command. Another option, as already suggested, is a dockable toolbar. These host controls that you can write in .Net so they can contain anything, including a text box.
Hello
Completly copied from Autodesk Inventor Programmers help:
Dockable window API Sample Description
This sample demonstrates creating a dockable window and adding a dialog into it.
Code Samples VBA Sample Code
You need to create the (modeless) dialog and set the hwnd of the dialog in the code below.
Sub DockableWindow() Dim oUserInterfaceMgr As UserInterfaceManager Set oUserInterfaceMgr = ThisApplication.UserInterfaceManager ' Create a new dockable window Dim oWindow As DockableWindow Set oWindow = oUserInterfaceMgr.DockableWindows.Add("SampleClientId", "TestWindowInternalName", "Test Window") ' Get the hwnd of the dialog to be added as a child ' CHANGE THIS VALUE! Dim hwnd As Long hwnd = 4851096 ' Add the dialog as a child to the dockable window Call oWindow.AddChild(hwnd) ' Don't allow docking to top and bottom oWindow.DisabledDockingStates = kDockTop + kDockBottom ' Make the window visible oWindow.Visible = True End Sub
© copyright 2012 Autodesk, Inc. | Comment on this page. |
I used the code in VBA. Now I tried it to use it in an add-in without success. Is there a Vb.Net sample code for it?
Thanks Georg
Hello
AFAIK there's no special Vb.Net sample code. The methods are the same.
Where exactly is the problem? "Doesn't work" is not very helpful.
Hello,
I tried thie sample:
But I could not get it to work. Does it run on your site?
Thanks
Georg