Example: biology

Introduction to Word Macros and Their Applications

ATA Conference 2005: Session TAC-7 Introduction to Word Macros and Their ApplicationsKarl F. PfeifferATA Conference 2005: Session TAC-7 Introduction to Word Macros and Their ApplicationsAbstract: Macros can assist with common tasks and are tools for automating repetitive processes. This presentation will providean Introduction to using Word Macros for translation tasks, preparing glossaries or other documents for MultiTerm or TMW import, and repetitive formatting or modifications. We will take first steps with visual Basic for Applications (VBA), the programming language for Word Macros , and see examples of recording and adapting Macros .

Karl Pfeiffer: Introduction to Word Macros 13 2.1. History (continued) http://en.wikipedia.org/wiki/Visual_Basic: “Visual Basic (VB) is an event driven programming language ...

Tags:

  Applications, Introduction, Programming, Basics, Their, Macro, Visual, Words, Visual basic, Introduction to word macros and their applications

Information

Domain:

Source:

Link to this page:

Please notify us if you found a problem with this document:

Other abuse

Transcription of Introduction to Word Macros and Their Applications

1 ATA Conference 2005: Session TAC-7 Introduction to Word Macros and Their ApplicationsKarl F. PfeifferATA Conference 2005: Session TAC-7 Introduction to Word Macros and Their ApplicationsAbstract: Macros can assist with common tasks and are tools for automating repetitive processes. This presentation will providean Introduction to using Word Macros for translation tasks, preparing glossaries or other documents for MultiTerm or TMW import, and repetitive formatting or modifications. We will take first steps with visual Basic for Applications (VBA), the programming language for Word Macros , and see examples of recording and adapting Macros .

2 Participants will also receive a WWW listing of downloadable Macros and a bibliography of relevant printed and on-line publications. Karl Pfeiffer: Introduction to Word Macros3 OverviewPurpose of MacrosVBA Concept and TerminologyIntroduction to VBA for MS WordVBA Applications for translatorsOnline learning and communityBibliographyKarl Pfeiffer: Introduction to Word Macros41. Purpose of : The purpose of Macros is to either automatefrequently-used sequencesor enable a more powerful abstraction but these are often the same thing..In most situations, the use of the word " macro " implies expanding a small command or action into a larger set of instructions.

3 Karl Pfeiffer: Introduction to Word Macros5 Purpose(continued)In other words : .. work more efficientlySub Macro1()'' Macro1 macro ' macro recorded 11/10/2005 by Karl Pfeiffer' Unit:= = Unit:=wdStoryEnd SubKarl Pfeiffer: Introduction to Word Case Study 1 Working with glossaries ..Example: tab-delimited bilingual glossaryTrados MTW file structureKarl Pfeiffer: Introduction to Word Case Study 1 What we have:Tab-delimited glossaryKarl Pfeiffer: Introduction to Word Case Study 1 What we want to get: Layout of MTW5 import/export fileKarl Pfeiffer: Introduction to Word Case Study 1 Working with glossaries.

4 Example: convert with macroKarl Pfeiffer: Introduction to Word Case Study 1 Solution: a conversion macro that performs repetitive tasksKarl Pfeiffer: Introduction to Word Concept and TerminologyVBA = visual Basic for ApplicationsKarl Pfeiffer: Introduction to Word : BASIC's name stands for Beginner's All-purpose Symbolic Instruction Code..BASICis a family of high-level programming languages. Originally devised as an easy-to-use programming language..It was devised in 1963by Profs. John G. Kemenyand Thomas E. Kurtzof Dartmouth College. Karl Pfeiffer: Introduction to Word History(continued) : visual Basic(VB) is an event driven programming languageand associated development environmentcreated by Microsoft.

5 In business programming , it has one of the largest user is derived heavily from of visual Basic for use in Applications : visual Basic for Applications (VBA) is included in many Microsoft Applications (like Microsoft Office). There are small inconsistencies in the way VBA is implemented in different Applications , but it is largely the same language as VB6. Karl Pfeiffer: Introduction to Word History(continued) : It supersedes and expands on the capabilities of earlier application-specific macro programming languagessuch as Word's WordBasic, and can be used to control almost all aspects of the host application, including manipulating user interface features such as menus andtoolbars and working with custom user forms or dialog boxes.

6 As its name suggests, VBA is closely related to visual Basic, but can normally only run code from within a host application rather than as a standalone application. It can however be used to control one application from another (for example automatically creating a Wordreport from Exceldata). Karl Pfeiffer: Introduction to Word is included in many Microsoft applicationsSo, where do we find it?Karl Pfeiffer: Introduction to Word Interface(continued)Tools > macro > visual Basic EditorCurrent version: Features: : Pfeiffer: Introduction to Word Interface(continued)Main VBE window3 sub-windows:* Project Explorer* Properties Window* Code WindowKarl Pfeiffer: Introduction to Word TerminologyProject: A set of modulesModule: file containing codes for Macros and proceduresProcedure: sequence of instructions that performs a specific taskKarl Pfeiffer: Introduction to Word Terminology (continued)Object-oriented programming (OOP):Object.

7 Specific characteristics and behavior, documents and tablesProperty: named attribute of an object, column width or row height of a tableMethod: action performed by an object, Sorting a table columnKarl Pfeiffer: Introduction to Word Macros203. Introduction to VBA for MS WordExample: tab-delimited bilingual glossarySettings: -fresh : C:\Documents and Settings\<user name>\Application Data\Microsoft\Templates- visual Basic Toolbar-Security-clear Require Variable DeclarationKarl Pfeiffer: Introduction to Word Macros213. Introduction (continued)Error message possibly due to corrupted Pfeiffer: Introduction to Word Macros223.

8 Introduction (continued)show visual Basic toolbarKarl Pfeiffer: Introduction to Word Macros233. Introduction (continued)Set security levelKarl Pfeiffer: Introduction to Word Macros243. Introduction (continued)Uncheck Require Variable DeclarationKarl Pfeiffer: Introduction to Word Macros253. Introduction (continued)Example: tab-delimited bilingual glossaryuse macro Recorder to get a head startKarl Pfeiffer: Introduction to Word Macros263. Introduction (continued)Karl Pfeiffer: Introduction to Word Macros273. Introduction (continued)Identify:ObjectsMethodsProper tiesKarl Pfeiffer: Introduction to Word Macros283.

9 Introduction (continued)Run macro from toolbarKarl Pfeiffer: Introduction to Word Macros293. Introduction (continued)Run macro step by step with F8 Karl Pfeiffer: Introduction to Word Macros303. Introduction (continued)Run macro step by step with F8 Edit code:Insert a loop structureKarl Pfeiffer: Introduction to Word Macros313. Introduction (continued)Edit code:Event-handling at end of document to stop the loopKarl Pfeiffer: Introduction to Word Macros323. Introduction (continued)Run macro step by step with F8define a counterKarl Pfeiffer: Introduction to Word Macros333.

10 Introduction (continued)Run macro step by step with F8 Increment counter with each loopKarl Pfeiffer: Introduction to Word Macros343. Introduction (continued)Send counter value to Message BoxKarl Pfeiffer: Introduction to Word Macros353. Introduction (continued)Display Message BoxNote: MultiTerm Convert (shipped with Trados 6) can convert tab-delimited files, as Pfeiffer: Introduction to Word Macros363. Introduction (continued)Case Study 2 Prepare TMW export for selective editKarl Pfeiffer: Introduction to Word Macros373. Introduction (continued)Structure of TMW exportKarl Pfeiffer: Introduction to Word Macros383.


Related search queries