基于catia二次开发下的车用弹簧建模设计毕业设计外文资料翻译内容摘要:
)。 VBA (Visual Basic for Applications) is a subset of Visual Basic, VBA is hosted in applications such as Word, Excel or CATIA. It provides a plete environment with an Editor, a debugger, a Help Object Viewer and Completion. The TOOLS+REFERENCE menu allows to declare the object library gives access to the pletion and the object (Visual Basic Script) is a subset of interpreted Basic language Can call CATIA type is used. The system tries dynamically to call methods and properties of objects. (Late binding calling objects through their IDispatch interface). Supported Languages The languages supported by CATIA are: CATScript : It is the language of the scripting in V5 until the inclusive V5R7. From the V5R8, it bees deprecated and it is advised to use rather MS VBScript or MS VBA. MSVBScript : It is the language to use first and foremost from the V5R8, and the only solution allowing to have a portability of the scripts in NT and UNIX. MSVBScript differs from CATScript by the fact that the notion to declare a variable by Dim X As Y does not exist. MSVBA : VBA is an environment of development integrated into CATIA and dedicated to VB but only on NT. MSVBA differs from MSVBScript by the fort of programming and the possibility of realizing simple application with a graphic interface. ActiveX with panels can be added in a macro but only on NT. Other services such as “ ” are called with “ CreateObject” and are available only on NT. The declaration of object types is recorded in the macro (even if it is not used in VBScript) but it can help you (with the pletion in VB on NT) to program your future application. CATIA V5 Association with file extension A doubleclick in Windows Explorer on a ” .CATPart” file opens it in CATIA V5. On NT, If CATIA V5 is not running, it is launched automatically. In the Windows Explorer, with “ As Web page” mode, a thumbnail shows a preview for all CATIA Documents. CATIA V5 Scripting capabilities IN process application:This is done from the Tools + Macro in CATIA menu. When the Macro is running, CATIA is deactivated. You cannot store variables in a macro between two calls. Access with VBScript (Microsoft) and VBA on Windows NT, and with VBScript (Winsoft) on Unix. This is based on AUTOMATION. A foreign process can call CATIA, create or modify geometry, decode, measure or pilot CATIA. CATIA is still running. For each action of the application, we have to check if CATIA is in the good state to synchronize the two processes. This kind of applications can be developed in: Visual Basic, Windows Scripting Host (VBScript , JScript),Windows Explorer HTML (VBScript , JScript)or Any other COM applications. In the future, a Java encapsulation of the V5 Automation objects will also be provided. This will enable the development of applications on NT and Unix based on Java, both inprocess and outprocess. InProcess Macros We call Inprocess because the script interpretation is performed in the same process as CATIA。 A list shows the Macro available. We can run, edit, rename or delete existing script, or create a new list of libraries of script proposed into the panel above is modifiable through the window of libraries. CATIA V5 Visual Basic Editor With CATIA Visual Basic Editor, We can edit existing macro or create a new one, insert graphic form, debug and run VBA project. Macro libraries The interface of the dialog “Tools + Macro + Macros„” allows to choose a library of macro (a directory of macro or a VBA project) or a document on which we wish to work. From this window, we can close an already opened library, open a library, or create a library. Libraries are shown by type (directory, VBA project...).Every type of library supports different languages. VBA supports only the language MSVBA, while in a directory we can write in MSVBScript or in CATScript. Recording a Macro The panel of recording VBA allows to choose the container in which we are going to record, the used language and the name of the macro to be syntax of the recorded script is going to differ according to the menu chosen. Recording a Macro generates a script corresponding to the creation or modification of the objects in the recorded sequence. After stopping the recording, we can store,edit or replay this script (called macro). As a rule, recording a macro helps you to learn how to program something。 Running a Macro You can execute a macro as soon as CATIA is started : CNEXT macro E:\Users\Macros\ You can start CATIA in batch mode to execute a macro: CNEXT batch macro。基于catia二次开发下的车用弹簧建模设计毕业设计外文资料翻译
阅读剩余 0%
本站所有文章资讯、展示的图片素材等内容均为注册用户上传(部分报媒/平媒内容转载自网络合作媒体),仅供学习参考。
用户通过本站上传、发布的任何内容的知识产权归属用户或原始著作权人所有。如有侵犯您的版权,请联系我们反馈本站将在三个工作日内改正。