Invoking Specific Tool Palette using LISP

I am new user of BricsCAD and want to automatically invoke a specific Tool Palette by entering a customize command.I am

using lisp for automating such task.Can anyone know how to do this?

Thanks in advance.

Comments

  • Hi Ajit,

    try the following
    [code]; TOGGLE TOOLPALETTE ON/OFF
    (defun C:TPT ()
        (if (= (getvar "_TPSTATE") 0)
            (command "._TOOLPALETTES")
            (command "._TOOLPALETTESCLOSE")
        )
    )[/code]

    Creates a command called TPT to toggle the toolpalette on/off

    Regards,

    Jason Bourhill

    CAD Concepts


  • Whoops, sorry misread your post. Not sure if there is something specific that you can use via LISP, but you could use some LISP to change the folder that points to the toolpalette you want to use.

    mentioned in this post
    https://forum.bricsys.com/discussion/19035

    Regards,

    Jason Bourhill

    CAD Concepts


  • Thanks Jason.

    Your lisp routine would be useful.

    But my scenerio is  -Supose I created a new Tool Palette named "Hex. Bolt".

    "Hex. Bolt" is not my current tool palette on tool palettes bar.I closed Tool Palette Bar.

     Now I want to inovke "Hex. Bolt" tool palette.When I run your routine it will open Tool Palettes Bar but current tool palette is 

    diffrent than "Hex. Bolt".So can u tell how I would directly invoke "Hex. Bolt" tool Palette? 

  • Hello Jason,

    Your suggested post is helpful and I got solution.

    Thanks 

  • Ajit: Is your solution a big secret or are you willing to share it with the forum?
  • Sorry Guys, I was quiet busy so didnt get time to elobarate the solution.

    For inovking a spcific tool palette from tool palette bar follow following steps-

    1. Create new directory which has same name as tool palette you want to invoke at

       "C:\Documents and Settings\AAN\Application Data\Bricsys\BricsCAD\V13\en_US\Support\ToolPalettes".Here AAN would be 

       replaced by u r login ID.

    2. Copy "Palettes" directory and BcTpCatalog.btc file to directory created in step 1

    3. Now  open BcTpCatalog.btc file from directory created in step 1.This is XML file and you can open it in Notepad.

       In this file you have to comment code for all tool palettes except one you want to invoke.You can do this as follows-

       

    4.Now change value of "toolpalettepath" system variable to

     " C:\Documents and Settings\AAN\Application Data\Bricsys\BricsCAD\V13\en_US\Support\ToolPalettes\Hex. Bolt\."

       Here "Hex. Bolt" would be replaced by name of directory you created in step 1.

    5.Now when you invoke tool palettes bar by using command "TOOLPALETTES" command it would directly invoke specified

      Tool Pallete.

     Thats it..

     your suggestions for improvements would be highly appricated.

    Thanks

This discussion has been closed.