SlideShare a Scribd company logo
1 of 16
Hello!
I am Ma. Wennilou Porazo
Instructor
1
Using
Variables and
Constants
After studying Lesson C, you should
be able to:
● • Include a static variable in code
● Code the TextChanged event procedure
● Create a procedure that handles more than one event
3
Modifying the Load and Click Event Procedures
4
Modifying the Load and Click Event Procedures
5
Coding the TextChanged Event Procedure
● TextChanged event
○ Occurs when the Text property value of a control
changes
6
Coding the TextChanged Event Procedure
(cont.)
● Can occur
○ The use enters data into the control
○ The code assigns data to the control’s Text
Property
● Example: A change is made to the number of items
ordered
7
Associating a Procedure with Different Objects
and Events
● Handles clause
○ Appears in an event procedure’s header
○ Indicates the object and event associated with
the procedure
8
Associating a Procedure with Different Objects and
Events (cont.)
● You can associate an event procedure with more
than or object and/ or event
○ In the Handles section of procedure header, list
each and event separated by commas
9
Associating a Procedure with Different Objects
and Events
● Procedure names are entered in Pascal case
○ Capitalize the first letter in the name and the first
letter of each subsequent word in the name
10
11
12
Lesson C Summary
● To process code when a change is made to the
contents of a control’s Text property:
○ Enter the code in the control’s TextChanged
event procedure.
13
Lesson C, Summary
● To associate a procedure with more than one object
or event:
○ List each object and event (using the syntax
object.event) after the Handles keyword in the
procedure header. Use a comma to separate an object
and event from the previous object and event.
14
Reference
● Book
○ Programming with Microsoft Visual Basic
2010, 5th edition
○ Author: Diane Zak
15
Thanks!
16

More Related Content

Similar to CHAPTER 3- Lesson C

Cucumber for automated acceptance testing.pptx
Cucumber for automated acceptance testing.pptxCucumber for automated acceptance testing.pptx
Cucumber for automated acceptance testing.pptx
Kalhan Liyanage
 

Similar to CHAPTER 3- Lesson C (11)

[DSC Europe 22] Engineers guide for shepherding models in to production - Mar...
[DSC Europe 22] Engineers guide for shepherding models in to production - Mar...[DSC Europe 22] Engineers guide for shepherding models in to production - Mar...
[DSC Europe 22] Engineers guide for shepherding models in to production - Mar...
 
PeopleSoft Test Framework Walkthrough
PeopleSoft Test Framework WalkthroughPeopleSoft Test Framework Walkthrough
PeopleSoft Test Framework Walkthrough
 
Cis160 Final Review
Cis160 Final ReviewCis160 Final Review
Cis160 Final Review
 
Oaf personalization examples
Oaf personalization examplesOaf personalization examples
Oaf personalization examples
 
Oaf personaliztion examples
Oaf personaliztion examplesOaf personaliztion examples
Oaf personaliztion examples
 
RPA Summer School Studio Session 2 - The Fundamentals of UiPath Studio .pdf
RPA Summer School Studio Session 2 - The Fundamentals of UiPath Studio .pdfRPA Summer School Studio Session 2 - The Fundamentals of UiPath Studio .pdf
RPA Summer School Studio Session 2 - The Fundamentals of UiPath Studio .pdf
 
UiPath Studio Session 2 - The Fundamentals of UiPath Studio - Final Slides.pdf
UiPath Studio Session 2 - The Fundamentals of UiPath Studio - Final Slides.pdfUiPath Studio Session 2 - The Fundamentals of UiPath Studio - Final Slides.pdf
UiPath Studio Session 2 - The Fundamentals of UiPath Studio - Final Slides.pdf
 
Chapter 4 — Variables and Arithmetic Operations
Chapter 4 — Variables and Arithmetic OperationsChapter 4 — Variables and Arithmetic Operations
Chapter 4 — Variables and Arithmetic Operations
 
copy control.pdf
copy control.pdfcopy control.pdf
copy control.pdf
 
Cucumber for automated acceptance testing.pptx
Cucumber for automated acceptance testing.pptxCucumber for automated acceptance testing.pptx
Cucumber for automated acceptance testing.pptx
 
7\9 SSIS 2008R2_Training - Script Task
7\9 SSIS 2008R2_Training - Script Task7\9 SSIS 2008R2_Training - Script Task
7\9 SSIS 2008R2_Training - Script Task
 

More from MLG College of Learning, Inc (20)

PC111.Lesson2
PC111.Lesson2PC111.Lesson2
PC111.Lesson2
 
PC111.Lesson1
PC111.Lesson1PC111.Lesson1
PC111.Lesson1
 
PC111-lesson1.pptx
PC111-lesson1.pptxPC111-lesson1.pptx
PC111-lesson1.pptx
 
PC LEESOON 6.pptx
PC LEESOON 6.pptxPC LEESOON 6.pptx
PC LEESOON 6.pptx
 
PC 106 PPT-09.pptx
PC 106 PPT-09.pptxPC 106 PPT-09.pptx
PC 106 PPT-09.pptx
 
PC 106 PPT-07
PC 106 PPT-07PC 106 PPT-07
PC 106 PPT-07
 
PC 106 PPT-01
PC 106 PPT-01PC 106 PPT-01
PC 106 PPT-01
 
PC 106 PPT-06
PC 106 PPT-06PC 106 PPT-06
PC 106 PPT-06
 
PC 106 PPT-05
PC 106 PPT-05PC 106 PPT-05
PC 106 PPT-05
 
PC 106 Slide 04
PC 106 Slide 04PC 106 Slide 04
PC 106 Slide 04
 
PC 106 Slide no.02
PC 106 Slide no.02PC 106 Slide no.02
PC 106 Slide no.02
 
pc-106-slide-3
pc-106-slide-3pc-106-slide-3
pc-106-slide-3
 
PC 106 Slide 2
PC 106 Slide 2PC 106 Slide 2
PC 106 Slide 2
 
PC 106 Slide 1.pptx
PC 106 Slide 1.pptxPC 106 Slide 1.pptx
PC 106 Slide 1.pptx
 
Db2 characteristics of db ms
Db2 characteristics of db msDb2 characteristics of db ms
Db2 characteristics of db ms
 
Db1 introduction
Db1 introductionDb1 introduction
Db1 introduction
 
Lesson 3.2
Lesson 3.2Lesson 3.2
Lesson 3.2
 
Lesson 3.1
Lesson 3.1Lesson 3.1
Lesson 3.1
 
Lesson 1.6
Lesson 1.6Lesson 1.6
Lesson 1.6
 
Lesson 3.2
Lesson 3.2Lesson 3.2
Lesson 3.2
 

Recently uploaded

會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
中 央社
 

Recently uploaded (20)

An overview of the various scriptures in Hinduism
An overview of the various scriptures in HinduismAn overview of the various scriptures in Hinduism
An overview of the various scriptures in Hinduism
 
philosophy and it's principles based on the life
philosophy and it's principles based on the lifephilosophy and it's principles based on the life
philosophy and it's principles based on the life
 
Andreas Schleicher presents at the launch of What does child empowerment mean...
Andreas Schleicher presents at the launch of What does child empowerment mean...Andreas Schleicher presents at the launch of What does child empowerment mean...
Andreas Schleicher presents at the launch of What does child empowerment mean...
 
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
 
Đề tieng anh thpt 2024 danh cho cac ban hoc sinh
Đề tieng anh thpt 2024 danh cho cac ban hoc sinhĐề tieng anh thpt 2024 danh cho cac ban hoc sinh
Đề tieng anh thpt 2024 danh cho cac ban hoc sinh
 
ANTI PARKISON DRUGS.pptx
ANTI         PARKISON          DRUGS.pptxANTI         PARKISON          DRUGS.pptx
ANTI PARKISON DRUGS.pptx
 
Graduate Outcomes Presentation Slides - English (v3).pptx
Graduate Outcomes Presentation Slides - English (v3).pptxGraduate Outcomes Presentation Slides - English (v3).pptx
Graduate Outcomes Presentation Slides - English (v3).pptx
 
Mattingly "AI and Prompt Design: LLMs with NER"
Mattingly "AI and Prompt Design: LLMs with NER"Mattingly "AI and Prompt Design: LLMs with NER"
Mattingly "AI and Prompt Design: LLMs with NER"
 
Mattingly "AI & Prompt Design: Named Entity Recognition"
Mattingly "AI & Prompt Design: Named Entity Recognition"Mattingly "AI & Prompt Design: Named Entity Recognition"
Mattingly "AI & Prompt Design: Named Entity Recognition"
 
male presentation...pdf.................
male presentation...pdf.................male presentation...pdf.................
male presentation...pdf.................
 
Mattingly "AI and Prompt Design: LLMs with Text Classification and Open Source"
Mattingly "AI and Prompt Design: LLMs with Text Classification and Open Source"Mattingly "AI and Prompt Design: LLMs with Text Classification and Open Source"
Mattingly "AI and Prompt Design: LLMs with Text Classification and Open Source"
 
IPL Online Quiz by Pragya; Question Set.
IPL Online Quiz by Pragya; Question Set.IPL Online Quiz by Pragya; Question Set.
IPL Online Quiz by Pragya; Question Set.
 
24 ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH SỞ GIÁO DỤC HẢI DƯ...
24 ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH SỞ GIÁO DỤC HẢI DƯ...24 ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH SỞ GIÁO DỤC HẢI DƯ...
24 ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH SỞ GIÁO DỤC HẢI DƯ...
 
demyelinated disorder: multiple sclerosis.pptx
demyelinated disorder: multiple sclerosis.pptxdemyelinated disorder: multiple sclerosis.pptx
demyelinated disorder: multiple sclerosis.pptx
 
e-Sealing at EADTU by Kamakshi Rajagopal
e-Sealing at EADTU by Kamakshi Rajagopale-Sealing at EADTU by Kamakshi Rajagopal
e-Sealing at EADTU by Kamakshi Rajagopal
 
Major project report on Tata Motors and its marketing strategies
Major project report on Tata Motors and its marketing strategiesMajor project report on Tata Motors and its marketing strategies
Major project report on Tata Motors and its marketing strategies
 
Analyzing and resolving a communication crisis in Dhaka textiles LTD.pptx
Analyzing and resolving a communication crisis in Dhaka textiles LTD.pptxAnalyzing and resolving a communication crisis in Dhaka textiles LTD.pptx
Analyzing and resolving a communication crisis in Dhaka textiles LTD.pptx
 
“O BEIJO” EM ARTE .
“O BEIJO” EM ARTE                       .“O BEIJO” EM ARTE                       .
“O BEIJO” EM ARTE .
 
The Story of Village Palampur Class 9 Free Study Material PDF
The Story of Village Palampur Class 9 Free Study Material PDFThe Story of Village Palampur Class 9 Free Study Material PDF
The Story of Village Palampur Class 9 Free Study Material PDF
 
Spring gala 2024 photo slideshow - Celebrating School-Community Partnerships
Spring gala 2024 photo slideshow - Celebrating School-Community PartnershipsSpring gala 2024 photo slideshow - Celebrating School-Community Partnerships
Spring gala 2024 photo slideshow - Celebrating School-Community Partnerships
 

CHAPTER 3- Lesson C

  • 1. Hello! I am Ma. Wennilou Porazo Instructor 1
  • 3. After studying Lesson C, you should be able to: ● • Include a static variable in code ● Code the TextChanged event procedure ● Create a procedure that handles more than one event 3
  • 4. Modifying the Load and Click Event Procedures 4
  • 5. Modifying the Load and Click Event Procedures 5
  • 6. Coding the TextChanged Event Procedure ● TextChanged event ○ Occurs when the Text property value of a control changes 6
  • 7. Coding the TextChanged Event Procedure (cont.) ● Can occur ○ The use enters data into the control ○ The code assigns data to the control’s Text Property ● Example: A change is made to the number of items ordered 7
  • 8. Associating a Procedure with Different Objects and Events ● Handles clause ○ Appears in an event procedure’s header ○ Indicates the object and event associated with the procedure 8
  • 9. Associating a Procedure with Different Objects and Events (cont.) ● You can associate an event procedure with more than or object and/ or event ○ In the Handles section of procedure header, list each and event separated by commas 9
  • 10. Associating a Procedure with Different Objects and Events ● Procedure names are entered in Pascal case ○ Capitalize the first letter in the name and the first letter of each subsequent word in the name 10
  • 11. 11
  • 12. 12
  • 13. Lesson C Summary ● To process code when a change is made to the contents of a control’s Text property: ○ Enter the code in the control’s TextChanged event procedure. 13
  • 14. Lesson C, Summary ● To associate a procedure with more than one object or event: ○ List each object and event (using the syntax object.event) after the Handles keyword in the procedure header. Use a comma to separate an object and event from the previous object and event. 14
  • 15. Reference ● Book ○ Programming with Microsoft Visual Basic 2010, 5th edition ○ Author: Diane Zak 15