S11-1 ADM704-705, Section 11, August 2005 Copyright  2005 MSC.Software Corporation SECTION 11 MACROS: OVERVIEW.

Slides:



Advertisements
Similar presentations
Introduction to Visual Basic.NET Uploaded By: M.Sheraz anjum.
Advertisements

1 Microsoft Access 2002 Tutorial 9 – Automating Tasks With Macros.
Developing an Excel Application
Tutorial 8: Developing an Excel Application
Objectives Understand the software development lifecycle Perform calculations Use decision structures Perform data validation Use logical operators Use.
Tutorial 12: Enhancing Excel with Visual Basic for Applications
© 2010 Delmar, Cengage Learning Chapter 9: Using ActionScript.
The Web Warrior Guide to Web Design Technologies
Finite Element Method FEM Dr. Mohammed Al-Hazmi ANSYS Basics Lecture 4.
Automating Tasks With Macros
Customizing Word Microsoft Office Word 2007 Illustrated Complete.
Automating Tasks With Macros. 2 Design a switchboard and dialog box for a graphical user interface Database developers interact directly with Access.
1 Chapter 4 The Fundamentals of VBA, Macros, and Command Bars.
Customizing Outlook. Forms Window in which you enter and view information in Outlook Outlook Form Designer The environment in which you create and customize.
About the Presentations The presentations cover the objectives found in the opening of each chapter. All chapter objectives are listed in the beginning.
Guide To UNIX Using Linux Third Edition
Introduction to Unix (CA263) Introduction to Shell Script Programming By Tariq Ibn Aziz.
COMPREHENSIVE Excel Tutorial 8 Developing an Excel Application.
Exploring Microsoft Excel 2002 Chapter 8 Chapter 8 Automating Repetitive Tasks: Macros and Visual Basic for Applications By Robert T. Grauer Maryann Barber.
Access Tutorial 10 Automating Tasks with Macros
Chapter 9 Introduction to ActionScript 3.0. Chapter 9 Lessons 1.Understand ActionScript Work with instances of movie clip symbols 3.Use code snippets.
WS2-1 ADM740, Workshop 2, June 2007 Copyright  2007 MSC.Software Corporation WORKSHOP 2 TEMPLATES VERSUS SUBSYSTEMS.
Introduction to Shell Script Programming
© Copyright 1992–2005 by Deitel & Associates, Inc. and Pearson Education Inc. All Rights Reserved. Tutorial 2 - Welcome Application: Introduction to C++
© 2008, Renesas Technology America, Inc., All Rights Reserved 1 Purpose  This training course describes how to configure the the C/C++ compiler options.
S1-1 ADM703, Section 1, August 2005 Copyright  2005 MSC.Software Corporation PART 1 ADVANCED MODELING AND BEST PRACTICES.
Microsoft Excel 2007 © Wiley Publishing All Rights Reserved. The L Line The Express Line to Learning L Line.
Automating Database Processing Chapter 6. Chapter Introduction Design and implement user-friendly menu – Called navigation form Macros – Automate repetitive.
WS16-1 ADM , Workshop 16, August 2005 Copyright  2005 MSC.Software Corporation WORKSHOP 16 WRAP-UP.
Copyright © 2008 Pearson Prentice Hall. All rights reserved. 11 Committed to Shaping the Next Generation of IT Experts. Chapter 10 Customizing a Database.
INTRO-1 ADM , Introduction, August 2005 Copyright  2005 MSC.Software Corporation WELCOME TO ADVANCED ADAMS/VIEW TRAINING.
S9-1 ADM , Section 9, August 2005 Copyright  2005 MSC.Software Corporation SECTION 9 COMMAND LANGUAGE.
WS4-1 ADM , Workshop 4, August 2005 Copyright  2005 MSC.Software Corporation WORKSHOP 4 PARAMETERIZING AN EXISTING MODEL.
Active-HDL Interfaces Debugging C Code Course 10.
Key Applications Module Lesson 21 — Access Essentials
WS6-1 ADM703, Workshop 6, August 2005 Copyright  2005 MSC.Software Corporation WORKSHOP 6 OVER-RUNNING PULLEY.
S5-1 ADM740, Section 5, June 2007 Copyright  2007 MSC.Software Corporation SECTION 5 PLOT CONFIGURATION FILES.
Microsoft Access 2013 ®® Tutorial 10 Automating Tasks with Macros.
WS12-1 ADM , Workshop 12, August 2005 Copyright  2005 MSC.Software Corporation WORKSHOP 12 MACROS AND PARAMETER SYNTAX.
S4-1 ADM703, Section 4, August 2005 Copyright  2005 MSC.Software Corporation SECTION 4 WASHING MACHINE.
WS11-1 ADM , Workshop 11, August 2005 Copyright  2005 MSC.Software Corporation WORKSHOP 11 MACROS: OVERVIEW.
S6-1 ADM740, Section 6, June 2007 Copyright  2007 MSC.Software Corporation SECTION 6 CREATING AND SIMULATING SUSPENSIONS.
Chapter 2: Introduction to HyperMesh Process Auomation
WS13-1 ADM740, Workshop 13, June 2007 Copyright  2007 MSC.Software Corporation WORKSHOP 13 EXPLORING AND COMPLETING TEMPLATES.
3 Copyright © 2004, Oracle. All rights reserved. Working in the Forms Developer Environment.
Exploring Microsoft Access Chapter 7 Building Applications: The Switchboard, Macros, and Prototyping.
XP New Perspectives on Microsoft Office Access 2003 Tutorial 10 1 Microsoft Office Access 2003 Tutorial 10 – Automating Tasks With Macros.
Visual Basic for Application - Microsoft Access 2003 Programming applications using Objects.
S5-1 ADM , Section 5, August 2005 Copyright  2005 MSC.Software Corporation SECTION 5 PARAMETERIZING A NEW MODEL.
WS3-1 ADM740, Workshop 3, June 2007 Copyright  2007 MSC.Software Corporation WORKSHOP 3 CREATING AND ADJUSTING SUSPENSIONS.
WS5-1 ADM , Workshop 5, August 2005 Copyright  2005 MSC.Software Corporation WORKSHOP 5 PARAMETERIZING A NEW MODEL.
WS2-1 ADM , Workshop 2, August 2005 Copyright  2005 MSC.Software Corporation WORKSHOP 2 EXPRESSIONS: OVERVIEW.
S15-1 ADM740, Section 15, June 2007 Copyright  2007 MSC.Software Corporation SECTION 15 EXPLORING TEMPLATES.
IE 411/511: Visual Programming for Industrial Applications Lecture Notes #2 Introduction to the Visual Basic Express 2010 Integrated Development Environment.
WS1-1 ADM , Workshop 1, August 2005 Copyright  2005 MSC.Software Corporation WORKSHOP 1 INTRODUCTION.
WS16-1 ADM740, Workshop 16, June 2007 Copyright  2007 MSC.Software Corporation WORKSHOP 16 Using Adams/Linear with Adams/Car.
S7-1 ADM730, Section 7, September 2005 Copyright  2005 MSC.Software Corporation SECTION 7 ADVANCED TOPICS.
S15-1 ADM , Section 15, August 2005 Copyright  2005 MSC.Software Corporation SECTION 15 DIALOG BOX BUILDER.
SECTION 6 DESIGN STUDY. What’s in this section: –Design Variables –Design Studies Overview –Specifying an Objective –Execution Display Settings –Output.
Excel Tutorial 8 Developing an Excel Application
SECTION 1 ADAMS/Solver subroutines overview
INTRODUCING Adams/CHASSIS
ADAMS/VIEW INTERFACE OVERVIEW
ADAMS/VIEW INTERFACE OVERVIEW
SECTION 3 MACROS: OVERVIEW.
WORKSHOP 3 GSE IMPORT.
Scripts & Functions Scripts and functions are contained in .m-files
Microsoft Access Illustrated
Microsoft Excel 2003 Illustrated Complete
Stata Basic Course Lab 2.
Presentation transcript:

S11-1 ADM , Section 11, August 2005 Copyright  2005 MSC.Software Corporation SECTION 11 MACROS: OVERVIEW

S11-2 ADM , Section 11, August 2005 Copyright  2005 MSC.Software Corporation

S11-3 ADM , Section 11, August 2005 Copyright  2005 MSC.Software Corporation MACROS: OVERVIEW n What’s in this section: u Macro Overview u Macro Object Parameters u Ways to Create Macros u Executing Macros u Debugging

S11-4 ADM , Section 11, August 2005 Copyright  2005 MSC.Software Corporation MACROS: OVERVIEW n Definition n Purpose n Types

S11-5 ADM , Section 11, August 2005 Copyright  2005 MSC.Software Corporation MACROS: OVERVIEW (CONT.) n Definition u A macro is an object that adds a command to the ADAMS/View language to execute a series of ADAMS/View commands. ADAMS/View treats a macro as it does all other ADAMS/View commands.

S11-6 ADM , Section 11, August 2005 Copyright  2005 MSC.Software Corporation MACROS: OVERVIEW (CONT.) n Purpose u Automate model building, simulating, and reviewing l Examples: n Generate a series of objects n Generate a series of plots for a simulation n Build an entire model (one for parts, one for joints, one for forces, and so on). u Automate user preferences You can also write macros to automate how you work in ADAMS/View. For example, you can: l Automatically turn icons on or off l Specify a certain grid size l Set whether or not to use the external ADAMS/Solver library, and so on. l Examples: n Icon settings (visibility, size, color) n Grid settings (on/off, size, and so on) n Solver preferences (use external/internal, save files, and so on)

S11-7 ADM , Section 11, August 2005 Copyright  2005 MSC.Software Corporation MACROS: OVERVIEW (CONT.) n Types u Parameterless l Executes the ADAMS/View commands stored in the macro. u With parameters l You can add parameters to a macro that will be evaluated when the macro is executed. l This makes the macro more generic.

S11-8 ADM , Section 11, August 2005 Copyright  2005 MSC.Software Corporation MACRO OBJECT PARAMETERS n To create a macro, you must specify: u Name (for database storage and reference). l We recommend that you save your macros in a user-created library. If you save them in the.gui library, they will not be upward compatible. l By default, macros are saved at the root level of the database. u A command that will run the macro. l The default is the macro name. u The commands the macro will execute. u What to do in case of a subsequent Undo.

S11-9 ADM , Section 11, August 2005 Copyright  2005 MSC.Software Corporation WAYS TO CREATE MACROS n Macro editor u Here, you enter the name of the macro and a unique command string that executes the macro.

S11-10 ADM , Section 11, August 2005 Copyright  2005 MSC.Software Corporation WAYS TO CREATE MACROS (CONT.) n Record/Replay u You can create a macro by recording a sequence of steps. Once you start the recording process, you perform the operations that you want to be included in the macro. Then, you stop the recording process and play it back. You can also save the macro you just recorded. n Reading text from a file u You can create a macro by using the Read command to read in an existing command file containing the commands to be executed. You can also assign a help file or text string to the macro that explains the macro’s use. u The file you supply that contains the macro definition is a standard command file but it can also contain parameters embedded in the commands and can have special comments at the top.

S11-11 ADM , Section 11, August 2005 Copyright  2005 MSC.Software Corporation WAYS TO CREATE MACROS (CONT.) u Example: macro read & file_name = "part_replicate_single_mac.cmd" & macro_name =.par_rep_single

S11-12 ADM , Section 11, August 2005 Copyright  2005 MSC.Software Corporation EXECUTING MACROS u When you create a macro, the command is added to ADAMS/View language. n Command line u Enter the command (with any applicable parameters) in the command line of the Command Window. Command line

S11-13 ADM , Section 11, August 2005 Copyright  2005 MSC.Software Corporation EXECUTING MACROS (CONT.) n Command Navigator u The Command Navigator displays a list of all ADAMS/View command keywords. When you select an object, a dialog box appears in which you enter parameters for executing the command. Selecting this command… Opens this dialog box

S11-14 ADM , Section 11, August 2005 Copyright  2005 MSC.Software Corporation EXECUTING MACROS (CONT.) n Custom dialog boxes u You can create a custom dialog box that, upon execution, executes a macro. n Other macros u If needed, a command within a macro can execute another macro.

S11-15 ADM , Section 11, August 2005 Copyright  2005 MSC.Software Corporation DEBUGGING n Using list information and temporary variables n Using the ADAMS Command Debugger n Crawl-walk-run approach

S11-16 ADM , Section 11, August 2005 Copyright  2005 MSC.Software Corporation DEBUGGING (CONT.) n Using list information and temporary variables u You can debug a macro if you: l Create it in pieces. l Store the pieces in variables. l Get list information on these variables. u For more information on building function expression strings in a macro, see the Knowledge Base Article 7477, available at: n Using the ADAMS Command Debugger u Used for heavy development u Unsupported and details undocumented

S11-17 ADM , Section 11, August 2005 Copyright  2005 MSC.Software Corporation DEBUGGING (CONT.) n Crawl-walk-run approach u Crawl - Learn the commands l Use interface to facilitate. l Execute by interface (GUI), Command Navigator, and so on. l Review commands and parameters (log file and Command Window). l Add to macro editor and test. u Walk - Add parameters and qualifiers l Declare parameters and simple qualifiers. l Substitute parameters into commands. l Test. l Add looping constructs, if necessary. l Use temporary variables.

S11-18 ADM , Section 11, August 2005 Copyright  2005 MSC.Software Corporation DEBUGGING (CONT.) u Run - Fine tune l Add comment lines l Remove dependencies (model object names, environment, and so on). l Add error trapping (using IF condition). l Add detailed qualifier, as needed.