DockableWindow

DockableWindow

Anonymous
Not applicable
1,637 Views
9 Replies
Message 1 of 10

DockableWindow

Anonymous
Not applicable

 Hi! I have a problem with my DockableWindow. I have designed it as userControl and load it with show.

And now I want to use the Inventor Shortcuts for example return but it seems as they are locked by inventor.

If I'm watching the KeyDown Event to on a Textboxcontrol I didn't get the event fired while pressing return. Is there an other way to turn off the ShortCuts.

 

Thanks a lot

 

Kind Regards

 

Bernhard

0 Likes
1,638 Views
9 Replies
Replies (9)
Message 2 of 10

jeff.pek
Community Manager
Community Manager

There were issues here that got fixed before Inventor 2011 released. So, the should just work now.

Is there a way that you can post your project?

 

Jeff

0 Likes
Message 3 of 10

Anonymous
Not applicable

Hi

I'm using AIP 2011 and WinXP SP3 and I'm still having this problem!?

 

here's my loading code for the uc:

private Inventor.DockableWindow dw;
private Tools.WorkDirBrowser.ucWorkDir dwc;

dw = m_inventorApplication.UserInterfaceManager.DockableWindows.Add(GlobalData.ID, "WorkDirControl", "Work Directory");
dwc = new Tools.WorkDirBrowser.ucWorkDir();
dw.AddChild(dwc.Handle);
dwc.Show();

dw.SetMinimumSize(100, 100);
dw.DockingState = DockingStateEnum.kDockLastKnown;
dw.Visible = true;

 and in the usercontrol I'm only using one Textbox to test it!

 

Thanks a lot

 

 

 

Bernhard

0 Likes
Message 4 of 10

jeff.pek
Community Manager
Community Manager

Hi Bernhard -

 

I'm not able to reproduce this. Here's a simple test add-in (in C#) that does something similar to what you're doing. Can you see if this works for you?

 

The project doesn't auto-register; you'll need to do that manually with regasm.

 

Jeff

0 Likes
Message 5 of 10

Anonymous
Not applicable

Hi Jeff,

 

Maybe it is because you are using a Form an not a Usercontrol!

 

Because in My code  the property "private Tools.WorkDirBrowser.ucWorkDir dwc;" is a usercontrol!

So I'm going to try it with a form!

 

Many ThanksSmiley Very Happy


Bernhard

Message 6 of 10

Anonymous
Not applicable

Hi Jeff,

 

you are right! When I'm using a form I don't have problems with the return button! But!!!!

I've added a listviewcontrol and a Toolstrip! When I'm using the toostrip I have no problem! Entering the Listview the Dockable window loses it's focus and when I'm trying to use the toolbar again It doesn't work. I have to click on the Dockable Window (activate ) and then it works with the toolstrip again!

 

Sorry I don't want to post my whole project!

 

Thanks

 

Bernhard

0 Likes
Message 7 of 10

jeff.pek
Community Manager
Community Manager

Hmmm. I see this same thing in a test project I made up. Not quite sure why this is happening.

I'll tinker around a bit.

 

We have definitely seen some interaction problems between .NET controls and Inventor; I'm not sure if this falls into that category; it seems of a different type.

 

Jeff

0 Likes
Message 8 of 10

jeff.pek
Community Manager
Community Manager

Hi again, Bernhard -

 

I think I found a partial solution to the toolstrip button issue. See the following article:

  http://blogs.msdn.com/b/rickbrew/archive/2006/01/09/511003.aspx

 

I verified that this worked in my test project.

I do notice that the button tooltips are still not showing unless you activate some other window, but that's a minor issue.

 

Jeff

0 Likes
Message 9 of 10

Anonymous
Not applicable

Hi Jeff,

 

many thanks for your help, but I'm using a Toolstrip (in my VS2005 project) as BreadCrumbbar and it doesn't work!

I've also tried this

http://stackoverflow.com/questions/2423234/make-a-form-not-focusable-in-c

But it makes no difference?

 

I don't know! And in the API Help is no really good sample!?

 

Thanks a lot!!

 

Bernhard

0 Likes
Message 10 of 10

jeff.pek
Community Manager
Community Manager

Hi again Bernhard. I'm not sure what to tell you.

If you want to send me your project, perhaps I can take a look and figure something out.

You can reach me at <first>.<last>@autodesk.com

 

Jeff

0 Likes