This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #https://help.alibre.com/articles/#!alibre-help-v28/create-and-modify-global-parameters | |
| # create a new global parameters set | |
| Params = GlobalParameters('Test') | |
| # add a distance parameter in millimeters | |
| Params.AddParameter('Width', ParameterTypes.Distance, 4.56) | |
| # save and close, replace with your own path | |
| Params.Save(r'C:\Users\<username>\Downloads\temp') | |
| Params.Close() | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #https://help.alibre.com/articles/#!alibre-help-v28/copy-sketch | |
| MyPart = Part('MyPart') | |
| Sketch1 = MyPart.AddSketch('Sketch1', MyPart.GetPlane('XY-Plane')) | |
| Sketch1.AddLines([0, 10, 0, 0, 10, 0, 10, 10], False) | |
| Sketch1.AddArcCenterStartAngle(5, 10, 10, 10, 180, False) | |
| Sketch2 = MyPart.AddSketch('Sketch2', MyPart.GetPlane('YZ-Plane')) | |
| Sketch2.CopyFrom(Sketch1) | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #https://help.alibre.com/articles/#!alibre-help-v28/cap-screw-iso-4762-bolts | |
| # Creates a metric socket cap screw using ISO 4762 | |
| # See: http://practicalmaintenance.wordpress.com/2009/01/30/socket-head-cap-screws-article-13/ | |
| # Size of screw | |
| Diameter = 3.0 | |
| Length = 30.0 | |
| # Measurements table containing H, F, E, T, C from web page |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #https://help.alibre.com/articles/#!alibre-help-v28/calculating-length-of-curves | |
| import sympy | |
| from sympy import * | |
| x = Symbol('x') | |
| formula = 2 * x**2 | |
| x_minimum = 5.0 | |
| x_maximum = 10.0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #https://help.alibre.com/articles/#!alibre-help-v28/bolt-creator | |
| MyPart = Part('My Part') | |
| XYPlane = MyPart.GetPlane('XY-Plane') | |
| HeadSketch = MyPart.AddSketch('Head', XYPlane) | |
| HeadSketch.AddCircle(0, 0, 10, False) | |
| BoltHead = MyPart.AddExtrudeBoss('Bolt Head', HeadSketch, 5, False) | |
| HeadBottomPlane = MyPart.AddPlane('Head Bottom', XYPlane, 5) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #https://help.alibre.com/articles/#!alibre-help-v28/assembly-constraints | |
| # create a new empty assembly | |
| Asm = Assembly("Test"); | |
| # add a part at the origin, replace path with your own | |
| NewPart1 = Asm.AddPart(r'C:\Users\<username>\Desktop\PartA.AD_PRT', 0, 0, 0) | |
| # duplicate the part | |
| NewPart2 = Asm.DuplicatePart(NewPart1.Name, 0, 0, 0) | |
| # anchor the original copy | |
| Asm.AnchorPart(NewPart1.Name); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """ | |
| Alibre Export Script | |
| """ | |
| import clr | |
| import sys | |
| from System import Environment, IO | |
| try: | |
| clr.AddReference('AlibreX') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #pragma once | |
| #include "frmconfiguration.h" | |
| #include "frmparameter.h" | |
| #include <ctype.h> | |
| namespace AlibreOOConnect { | |
| using namespace System; | |
| using namespace System::ComponentModel; | |
| using namespace System::Collections; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from __future__ import division # This fixes division with integers. For example the 1 / 2 = 0.5 instead of 0 | |
| import os # for working with file paths | |
| import clr | |
| import _winreg | |
| from AlibreX import ADUnits, ADDrawingViewType, ADDetailingOption, ADViewOrientation, IAD2DPoint, IADTransformation | |
| Win = Windows() | |
| def InputChanged(Index, Value): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| https://help.alibre.com/articles/#!alibre-help-v27/wrap Pro | |
| https://help.alibre.com/articles/#!alibre-help-v27/workspace-preferences-working-with-redlines Pro | |
| https://help.alibre.com/articles/#!alibre-help-v27/workspace-preferences-menu-structure-toolbars Pro | |
| https://help.alibre.com/articles/#!alibre-help-v27/workspace-preferences-menu-structure-custom-toolbars Pro | |
| https://help.alibre.com/articles/#!alibre-help-v27/workspace-preferences-grid-snapping-to-the-grid Pro | |
| https://help.alibre.com/articles/#!alibre-help-v27/workspace-preferences-grid-showing-or-hiding-the-grid Pro | |
| https://help.alibre.com/articles/#!alibre-help-v27/workspace-preferences-grid-setting-the-grid Pro | |
| https://help.alibre.com/articles/#!alibre-help-v27/workspace-preferences-about-split-views Pro | |
| https://help.alibre.com/articles/#!alibre-help-v27/using-menus Pro | |
| https://help.alibre.com/articles/#!alibre-help-v27/thread-data Pro |