DeskProto user forum
Forum: communicate with other users.
|
|
![]() From several DeskProto users we have heard very enthusiastic stories about MoI: Moment of Inspiration, which is a lowcost and easy-to-use 3D CAD program. See moi3d.com Like any 3D CAD program MoI offers STL export, so integration with DeskProto is easy. Some users nevertheless prefer an even easier integration, which can be done by adding a DeskProto button to MoI. And that appears to be quite easy: see the instructions below. You will need: - an image file for the button (64x64 pixels), we used DeskProtoIcon.png, shown above. Save that using a right mouse click and 'Save picture as' - a code snippet to be copied into the MoI code, see below. Instructions: 1. Copy the image file [DeskProtoIcon.png] to C:Program Files\MoI 2.0\ui\icons (or the appropriate path name for MoI trial or for a different version). 2. Open in a plain text editor file C:Program Files\MoI 2.0\ui\CommandBar.htm The last default button to be defined in this code is the Object Snap button. Insert the appropriate code snippet immediately after the code for the Object Snap button and then save this HTM file. You can see what needs to be done in one of the illustrations later in this forum thread. When you now start MOI the new DeskProto icon should be present. It will select all geometry, export it as STL file and then start DeskProto with this STL file loaded. Warning: Important is that the button always uses the same STL filename. So when you use the button for a second project, the first STL file will be deleted. This means that saving the DeskProto project is not useful, as when you later again open that project the STL geometry may have changed. |
|
![]() Here is the illustration for MOI V2.0, with code snippets. For DeskProto V6.0 the code snippet is: <!-- Start code for DeskProto button, by Delft Spline Systems --> <noscript> Oops, scripts are not permitted on the forum, so the code snippets do not come through. So I have made a ZIP file containing the icon file and these four code snippet files: [MOI2-DP60button-code.txt] [MOI2-DP61button-code.txt] [MOI3-DP60button-code.txt] [MOI3-DP61button-code.txt] You can download the file DPbutton-for-MoI.zip (10 Kb) here. |
|
![]() And finally the illustration for MoI V3.0. Lex. |
|
![]() MoI screen |
|
![]() And here after pressing the DP button. |
|
The button code already has been improved, thanks to MoI programmer Michael :-) The code snippets and the images above have been updated. |
|
![]() If is of course very well possible to adapt the button script code according to your needs. The example above (made by German reseller Filou) makes the name of each saved STL file unique by adding date and time to the filename. Then the file will not be deleted the next time that MOI's DeskProto button is pressed, which makes it possible to save the DeskProto project. Feel free to change the button script to make it do exactly what you want: scripting is a very powerful tool ! |
|
Hi Lex I am new in DeskProto, can you please tell me which editor do you use to write the scripts. Thank you so much Lam |
|
Hi Lam, You can use any plain text editor. I use both Textpad (a quite old license) and Notepad++. Lex. |
|
|
|