Results 1 to 4 of 4

Thread: how to manipulate a specific menuItem or a button in customer menubar / toolbar ?

  1. #1
    Member
    Join Date
    2008-11
    Posts
    23
    Login to Give a bone
    0

    Smile how to manipulate a specific menuItem or a button in customer menubar / toolbar ?

    Hi,

    If someone know how to manipulate the menuItem/submenuItem or a button in customer menubar/toolbar by Visual Basic 6 (note: not VBA) ? This means that one menuItem is selected or one buttom is clicked by the code Visual Basic 6.

    I actually work with AutoCAD 2000

    Thanks very much

  2. #2
    The Silent Type RobertB's Avatar
    Join Date
    2000-01
    Location
    Seattle WA USA
    Posts
    5,859
    Login to Give a bone
    0

    Default Re: how to manipulate a specific menuItem or a button in customer menubar / toolbar ?

    If you mean using the UI itself from VB6, I don't think it is possible. You cannot use VB6 to push a toolbar button, for example.
    R. Robert Bell
    Design Technology Manager
    Stantec
    Opinions expressed are mine alone and do not reflect the views of Stantec.

  3. #3
    Active Member
    Join Date
    2007-12
    Posts
    68
    Login to Give a bone
    0

    Default Re: how to manipulate a specific menuItem or a button in customer menubar / toolbar ?

    Quote Originally Posted by RobertB View Post
    If you mean using the UI itself from VB6, I don't think it is possible. You cannot use VB6 to push a toolbar button, for example.
    Are you sure of this? Ive written many routines to hijack other applications menus and controls, but cant say that Ive specifically hijacked an autocad toolbar.

    But firing up spy++, I see the toolbar, and each button, has its own hWnd, and hDc, and seems to be accepting standard windows messages. I dont see any class names, or unique identifiers there, which would make the code one-of-a-kind, but it still looks doable (although Im not going to be the one to do it)

    Am I missing something?

  4. #4
    The Silent Type RobertB's Avatar
    Join Date
    2000-01
    Location
    Seattle WA USA
    Posts
    5,859
    Login to Give a bone
    0

    Default Re: how to manipulate a specific menuItem or a button in customer menubar / toolbar ?

    Quote Originally Posted by B_Roche View Post
    Are you sure of this? ...
    But firing up spy++, I see the toolbar, and each button, has its own hWnd, and hDc, and seems to be accepting standard windows messages. I dont see any class names, or unique identifiers there, which would make the code one-of-a-kind, but it still looks doable
    Although you can get to the hWnd, without unique IDs it might get difficult. It sounds like you are the expert, so I'm happy to defer to your skills.
    R. Robert Bell
    Design Technology Manager
    Stantec
    Opinions expressed are mine alone and do not reflect the views of Stantec.

Similar Threads

  1. 2014: Using MTP w/ROTATE in toolbar button
    By straits58 in forum AutoCAD Customization
    Replies: 9
    Last Post: 2014-08-22, 11:36 AM
  2. Create a toolbar button
    By ccowgill in forum AutoLISP
    Replies: 2
    Last Post: 2009-06-29, 04:16 PM
  3. Would like Toolbar description to appear under toolbar button
    By danny.139703 in forum AutoCAD General
    Replies: 1
    Last Post: 2007-05-21, 05:47 PM
  4. Is there an easy way to have a Toolbar button call up another Toolbar?
    By jonathanschade in forum AutoCAD CUI Menus
    Replies: 5
    Last Post: 2007-04-12, 04:40 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •