Image : http://www.flickr.com
If you are already familiar with the programming language AutoLISP AutoCAD, your next natural step for a higher level of programming Visual Basic LISP (VLISP). VLISP offers several advantages over AutoLISP. Its full IDE (Integrated Development Environment) includes a debugger, syntax checking, automatic indentation and code formatting, and compiling code for the security, its interface is very similar to VBA (Visual Basic for Applications) IDE. VLISP continues the legacy ofAutoLISP developers and ensures that future versions of AutoCAD AutoLISP offer Visual Basic as an option for customization.
Access ActiveX objects from AutoLISP code provides the same object model, properties and methods that are available from the C + +, Visual Basic and Delphi programming environments with the syntax you already know. As an added bonus, you can integrate AutoCAD with Microsoft Office and other Visual Basic Windows programs that supportActiveX methodology.
Objects
AutoCAD objects that are already familiar with, include lines, arcs, circles, and text. These are the main components of the application of ActiveX. ActiveX, line types, dimensions and text styles, layers, groups, blocks, windows, model space and paper space, the design and application of AutoCAD, are represented as objects. Refer to the AutoCAD Visual Basic LISP and the section under the Help ActiveX ActiveX and VBA Reference to see thecomplete object model, methods, properties and events.
The AutoCAD object model follows a hierarchical structure. Visual Basic The Application object is on top of AutoCAD or root. Visual Basic All objects in the object model are grouped into collections. For example, the collection of documents contains all the drawings AutoCAD open in the current session. The object of active document is Visual Basic selected the current design. The collection contains all the blocks in AutoCAD drawing blocks, and the card collection area isa special lock object containing all the players in the paper space layout.
Each object within the model provides access to the next level of objects, and one or more properties. A line object is described by properties such as the start point, endpoint, linetype, or color. Properties such as radius, area and type of line to describe a circle object.
Objects also contain methods, which are the actions available for a specific object. Some methods can be applied to mostAutoCAD drawing objects, Visual Basic for example, moving the mirror method - but others apply only to objects such as line, arc, circle and ellipse.
VLISP functions
Yes Access Objects ActiveX VLISP through a set of functions added to the language AutoLISP. These functions use the prefix-VLA as follows:
* These functions invoke the corresponding methods VLA-ActiveX, for example, VLA-AddLine AddLine invokes the method.
* Vla-get-These functions invoke the correspondingActiveX properties, Visual Basic for example, vla-get-color get a color object properties.
VLA-put-* This function corresponds to each update of the property value of that property, for example, updates to VLA-Color-the color of objects of property.
A general set of related functions allow access to ActiveX ActiveX objects or custom objects from other applications, such as an Access database. VLISP AutoLISP provides the following functions whose names are preceded by Vlax-and apply methods,objects and properties:
* Calls Vlax invoke-method, a method ActiveX directly.
* Returns Vlax-get-property of an ActiveX object,
* Updates Vlax-put-property Visual Basic owned by an ActiveX object.
Making the transition from AutoLISP to VLISP is not as difficult as you might think. Once familiar with the IDE VLISP, editing and debugging tools, you'll wonder how you worked without them. You should begin to edit files in AutoLISP for VLISPfamiliarity with the IDE. To insert the IDE type VLISP VLISP AutoCAD, AutoCAD command prompt and start programming.
asp great zone fashion games garmin nuvi gps store
No comments:
Post a Comment