Unit 1.2 Introduction to Programming

21
Introduction to Programming Unit 1.2 - Introduction to Source Code Presentation 1

Transcript of Unit 1.2 Introduction to Programming

Page 1: Unit 1.2 Introduction to Programming

Introduction to Programming

Unit 1.2 - Introduction to Source Code

Presentation 1

Page 2: Unit 1.2 Introduction to Programming

Revision…

1. Define Task Pane.2. Explain the need for Microsoft Script

editor.3. __________ is a horizontal bar that

appears at the top of the active window which is associated with pull-down menus.

4. _______ is a collection of icons that provides easy access commonly used menu commands.

Page 3: Unit 1.2 Introduction to Programming

Objectives

At the end of this presentation, you will be able to:• List various tags used in the source code• Identify the tags used in the source code

Page 4: Unit 1.2 Introduction to Programming

Introduction

• Office is an application which is based on GUI interface.

• Each command in this application is coded using programming languages and other scripting languages.

• You can view the source code of each command using the Microsoft Script Editor.

Page 5: Unit 1.2 Introduction to Programming

Backbone of Office Applications

• Source code has both xml and html tags.

• XML is used to describe the data.

• XML code is enclosed within the tags <XML> … </XML>.

• HTML is used to format the data.

• HTML code is enclosed within the tags <HTML> … </HTML>.

Page 6: Unit 1.2 Introduction to Programming

Hands-On!

• Open the Microsoft script editor of a blank document and observe the XML and HTML code.

Page 7: Unit 1.2 Introduction to Programming

Lab Exercise

• Open a blank document. Observe the source code in Microsoft Script Editor.

• Open a blank workbook. Observe the source code in Microsoft Script Editor.

• Open a blank presentation. Observe the source code in Microsoft Script Editor.

Page 8: Unit 1.2 Introduction to Programming

Basic HTML Tags

• Some of the basic HTML tags that are commonly used are: Head tag

Body tag

Paragraph tag

Heading tag

Page 9: Unit 1.2 Introduction to Programming

Head Tag

• Provides information that does not affect the document but provides information to the browser when publishing the document on web.

• The necessary codes have to be enclosed within the tags <head> and </head>.

Page 10: Unit 1.2 Introduction to Programming

Activity 1.2.1

• Open the data file Malaysia.doc. Identify the head tag and the data enclosed within this tag.

Page 11: Unit 1.2 Introduction to Programming

Body Tag

• Specifies the beginning and end of the document.

• The necessary codes have to be enclosed within the tags <body> and </body>.

Page 12: Unit 1.2 Introduction to Programming

Hands-On!

• Open the data file Food.doc . Identify the body tag and the data enclosed within this tag.

Page 13: Unit 1.2 Introduction to Programming

Paragraph Tag

• Is used for creating paragraphs.

• The necessary codes have to be enclosed within the tags <p> and </p>.

Page 14: Unit 1.2 Introduction to Programming

Hands-On!

• Open the data file About_Malaysia.doc. Identify the paragraph tag and the data enclosed within this tag.

Page 15: Unit 1.2 Introduction to Programming

Heading Tag

• Specifies different sizes and styles for the heading.

Page 16: Unit 1.2 Introduction to Programming

Hands-On!

• Open the data file Heading.doc. Identify the different heading tags.

Page 17: Unit 1.2 Introduction to Programming

Activity 1.2.2

• Identify any two pair of tags present in the following code:

<html><body lang=EN-GB style='tab-

interval:.5in'><p class=MsoNormal><span lang=EN-

US>COOL</span></p></body></html>

Page 18: Unit 1.2 Introduction to Programming

Lab Exercise

• Open a blank document and type your name. Copy and paste the text five times. Save the document as Name.doc. Identify the various tags used in the source code.

Page 19: Unit 1.2 Introduction to Programming

Summary

In this presentation, you learnt the following:• Tags are the instruction which specifies how

the document appears.• The head tag provides information that does

not affect the document but provides information to the browser when publishing the document on web.

Page 20: Unit 1.2 Introduction to Programming

Summary

In this presentation, you learnt the following:• The body tag specifies the beginning and

end of the document.• The paragraph tag is used for creating

paragraphs. • Heading tag specifies different sizes and

styles for the heading.

Page 21: Unit 1.2 Introduction to Programming

Assignment

List any four tags used in script editor.

Identify any three tags in the following:<html><body lang=EN-GB style='tab-interval:.5in'><h2><span class=GramE><span lang=EN-US>sadsha</span>

</span></h2></body></html>