.NET
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Inspector (arx) cool features

6 REPLIES 6
Reply
Message 1 of 7
mikefr
651 Views, 6 Replies

Inspector (arx) cool features

Hello all,

I have been using the arx application "inspector.arx" and i noticed some cool features this app has:


1. Inspector doesn't steal focus from autocad when the refresh button is clicked. Generally inspector doesn't steal focus.


2. Inspector can be docked like a palette


3. Autocad is always active when the mouse leaves the inspector form.

Is it possible to create an app with .net with similar features? Imagine a form with buttons, labels, listviews... etc.
Can anyone provide some tips or guidance to achieve that?

Thanks a lot!

6 REPLIES 6
Message 2 of 7
Alfred.NESWADBA
in reply to: mikefr

Hi,

 

>> Is it possible to create an app with .net with similar features? Imagine a form

That's imho the difference, you are speaking from a Windows-Form-object, but not from a palette-/paletteset-object. Make custom controls instead of Windows-Forms and place these on PaletteSet-objects. Makes all much easier, not just focus.

>>>here<<< is a sample done by Kean Walmsley.

 

- alfred -

------------------------------------------------------------------------------------
Alfred NESWADBA
Ingenieur Studio HOLLAUS ... www.hollaus.at ... blog.hollaus.at ... CDay 2024
------------------------------------------------------------------------------------
(not an Autodesk consultant)
Message 3 of 7
mikefr
in reply to: Alfred.NESWADBA

Hi Alfred, I follow Kean's blog. He's done great job. I also tried palette but had problem with comboboxes. I use API version 17.2. Also when using a palette, you have to use custom controls to make them not stealing focus:

Public Class myButton
    Inherits Windows.Forms.Button

    Public Sub New()
        MyBase.New()
        SetStyle(Windows.Forms.ControlStyles.Selectable, False)
    End Sub

End Class

 I even tried using  the  ToolStripDropDown class. What i want is a smooth back n forth from a modeless form to autocad application. Creating your own commands is cool but you can't remember 100 commands... Instead you can create a form with buttons, settings and stuff.

Message 4 of 7
Alfred.NESWADBA
in reply to: mikefr

Hi,

 

>> Kean's blog. He's done great job

Yes!

 

>> but had problem with comboboxes

Correct, but I thought this workaround was not necessary since working base on Framework 3.5. But I'm not sure about this at the moment.

 

>> What i want is a smooth back n forth from a modeless form to autocad application.

>> Creating your own commands is cool but you can't remember 100 commands.

Forms will ever be a bit more work to sync the focus, the mouse/cursor, the visible or hidden (or minimized) mode with the AutoCAD-application window.

What I don't understand is the "100 commands" message? You can also place buttons on your usercontrol (on your palette) and that can start everything without needing any commands defined.

 

- alfred -

------------------------------------------------------------------------------------
Alfred NESWADBA
Ingenieur Studio HOLLAUS ... www.hollaus.at ... blog.hollaus.at ... CDay 2024
------------------------------------------------------------------------------------
(not an Autodesk consultant)
Message 5 of 7
mikefr
in reply to: Alfred.NESWADBA

I just want to mention that a UI is the best solution when you create lots of commands. Something i noticed in inspector is that when it is clicked autocad doen't lose focus. Inspector looks like a form. I hope for some guidance to create a form with similar features. By the way is there any workaround for the combobox glitch?

Message 6 of 7
HomeBoyLV
in reply to: mikefr

Trap the MouseEnter/MouseLeave events of your pallet and set the KeepFocus property. Always worked for me.

 

HomeBoy Out

Message 7 of 7
mikefr
in reply to: HomeBoyLV

Hi Homeboy, I have tried KeepFocus but no trapping the events. Do you mean creating a new class that inherits paletteset and overriding these two events?  When the events fire i change the KeepFocus propertie?

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk DevCon in Munich May 28-29th


Autodesk Design & Make Report

”Boost