Map .js to SpaceExplorer button
Moderator: Moderators
Map .js to SpaceExplorer button
I work in ANSYS Mechanical a bit, and I often need to hide several bodies when doing multibody analysis. It is cumbersome to have to use my normal mouse to first select a part and then go in the tree menu and click "hide/show part". I have created a javascript that will basically do the same for me. Is it possible in any way to map this script to one of my SpaceExplorer buttons? e.g. button 1?
Re: Map .js to SpaceExplorer button
Can you execute your script by means of a series of keystrokes?
If you can, you can record those keystrokes and play them back.
On the 'Button Configuration' Tab in the '3Dconnexion Control Panel',
(Start, All Programs, 3Dconnexion, 3Dconnexion Control Panel, with your application open and holding the Windows' Focus.)
Click on the 'Custom Functions' Buttons.
You may make up a 'title' for your keystrokes.
Then you may record those keystrokes.
Then next when you access the 'Button Configuration' Tab, you will see a listing for the 'title' you created, in the key drop-downs, and may select it to be assigned to a button.
Then when you press that button it will play back those key strokes to launch your javascript.
If you can, you can record those keystrokes and play them back.
On the 'Button Configuration' Tab in the '3Dconnexion Control Panel',
(Start, All Programs, 3Dconnexion, 3Dconnexion Control Panel, with your application open and holding the Windows' Focus.)
Click on the 'Custom Functions' Buttons.
You may make up a 'title' for your keystrokes.
Then you may record those keystrokes.
Then next when you access the 'Button Configuration' Tab, you will see a listing for the 'title' you created, in the key drop-downs, and may select it to be assigned to a button.
Then when you press that button it will play back those key strokes to launch your javascript.
The more things change, the more they remain the same. ; ^ )
Re: Map .js to SpaceExplorer button
You have two other options:
1) Install the 3DxWare 10 beta and you can define an executable/script that is called when you press a button. It's also called when you release it.
2) There is a registry entry (HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\explorer\AppKey\18) that defines a program that gets run when you press one of the Application Keys. This is currently most likely assigned to calc.exe. Some keyboards have Application Keys (2 of them). One of those, I forget which, executes whatever is in that registry entry. One of the 3DxWare button functions "Launch App1" or "Launch App2" will execute that function if you assign it to a key.
1) Install the 3DxWare 10 beta and you can define an executable/script that is called when you press a button. It's also called when you release it.
2) There is a registry entry (HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\explorer\AppKey\18) that defines a program that gets run when you press one of the Application Keys. This is currently most likely assigned to calc.exe. Some keyboards have Application Keys (2 of them). One of those, I forget which, executes whatever is in that registry entry. One of the 3DxWare button functions "Launch App1" or "Launch App2" will execute that function if you assign it to a key.
