SlideShare a Scribd company logo
1 of 28
VB6VB6
•VB6VB6ModulesModulesForm ModulesForm Modules
•EventsEvents((Key EventsKey EventsMouse EventsMouse Events
•Built-in(VB6VB6VB6VB6
•User-Defined(Sub ProceduresSub ProceduresFunction ProcedureFunction Procedure
IDEIDE:(:(
•Code WindowCode WindowProject1-Form1 (CodeProject1-Form1 (Code((Add ProcedureAdd Procedure
ToolsTools..
•CalculateCalculate))TypeTypeSubSubScopeScopePublicPublicOKOK
•End SubEnd SubEnd FunctionEnd Function
Sub ProceduresSub Procedures((
]]Accessing Type] Sub Procedure Name (Parameter ListAccessing Type] Sub Procedure Name (Parameter List((
StatementsStatements
End SubEnd Sub
Procedure Name ( [Parameter ListProcedure Name ( [Parameter List[ ([ (
11:(:(
Private Sub Command_ClickPrivate Sub Command_Click( )( )
Dim X, Y, Z As IntegerDim X, Y, Z As Integer
X = 40X = 40
Y = 135Y = 135
Z = 90Z = 90
Max (X, Y, Z)Max (X, Y, Z)
End SubEnd Sub
Private Sub Max (A, B, C, As Integer)Private Sub Max (A, B, C, As Integer)
Dim Answer As IntegerDim Answer As Integer
Answer = AAnswer = A
If B > Answer Then Answer = BIf B > Answer Then Answer = B
If C > Answer Then Answer = CIf C > Answer Then Answer = C
Print "Maximum Value =" ; AnswerPrint "Maximum Value =" ; Answer
End SubEnd Sub
Sub FunctionsSub Functions((
•FunctionFunctionSubSubReturn a ValueReturn a ValueTypeType..
•
Private Sub Command – Click ( )Private Sub Command – Click ( )
Dim X, Y, Z, S, P As RealDim X, Y, Z, S, P As Real
X = 2.8X = 2.8
Y = 12.5Y = 12.5
Z = 30.2Z = 30.2
Print "Summation of X,Y and Z =" Sum (X, Y, Z)Print "Summation of X,Y and Z =" Sum (X, Y, Z)
Print "Product of X,Y, and Z = "; Prod (X, Y, Z)Print "Product of X,Y, and Z = "; Prod (X, Y, Z)
End SubEnd Sub
Public Function Sum (A, B, C, As double) As doublePublic Function Sum (A, B, C, As double) As double
Sum = A + B + CSum = A + B + C
End FunctionEnd Function
Public Function Prod (A, B, C, As double) As doublePublic Function Prod (A, B, C, As double) As double
Prod = A * B * CProd = A * B * C
End FunctionEnd Function
Mathematical Functions
•VB6VB6
String Function:
StringString
Conversion Functions
Checking Functions
Procedure's CallingProcedure's Calling
FunctionFunctionSubSubCalling StatementCalling Statement
]]Call ] Procedure Name ( [ Parameter ListCall ] Procedure Name ( [ Parameter List[ ([ (
]]CallCall[[
Procedure NameProcedure Name
::Parameter ListParameter List
•ParametersParameters
•
•11..Call By ValueCall By Value((
22..((Call By ReferenceCall By Reference
11..Call By ValueCall By Value((
•
•
•By ValBy Val
Call By ValueCall By Value((
Private Sub MainPrivate Sub Main( (( (
Dim A, B As IntegerDim A, B As Integer
A = 12A = 12
B = 10B = 10
Print " Before Calling: A= ";A; "B= "; BPrint " Before Calling: A= ";A; "B= "; B
Call Calculate ( ByVal A, ByVal BCall Calculate ( ByVal A, ByVal B((
Print "After Calling : A = ";A; "B = " ; BPrint "After Calling : A = ";A; "B = " ; B
End SubEnd Sub
Private Sub Calculate (A As Integer, B As Integer)Private Sub Calculate (A As Integer, B As Integer)
Print "Values in Subroutine Before Any Calculations:"Print "Values in Subroutine Before Any Calculations:"
Print "A= " ; A; "B ="; BPrint "A= " ; A; "B ="; B
A = A + B + 8A = A + B + 8
B = B ^ 2 + 20B = B ^ 2 + 20
Print " Values in Subroutine After Calculations:"Print " Values in Subroutine After Calculations:"
Print "A=" ; A; " B=" ; BPrint "A=" ; A; " B=" ; B
End SubEnd Sub
Before Calling: A = 12 B = 10Before Calling: A = 12 B = 10
Values in Subroutine Before Any CalculationValues in Subroutine Before Any Calculation::
A = 12 B = 10A = 12 B = 10
Values in Subroutine After CalculationValues in Subroutine After Calculation::
A = 30 B = 120A = 30 B = 120
22..((Call By ReferenceCall By Reference
•
•..
•By RefBy Ref
Private Sub Main ( )Private Sub Main ( )
Dim A, B As IntegerDim A, B As Integer
A = 12A = 12
B = 10B = 10
Print " Before Calling: A= ";A; "B= "; BPrint " Before Calling: A= ";A; "B= "; B
Call Calculate ( ByRef A, ByRef B)Call Calculate ( ByRef A, ByRef B)
Print "After Calling : A = ";A; "B = " ; BPrint "After Calling : A = ";A; "B = " ; B
End SubEnd Sub
Private Sub Calculate (A As Integer, B As IntegerPrivate Sub Calculate (A As Integer, B As Integer((
Print "Values in Subroutine Before Any CalculationsPrint "Values in Subroutine Before Any Calculations:":"
Print "A= " ; A; "B ="; BPrint "A= " ; A; "B ="; B
A = A + B + 8A = A + B + 8
B = B ^ 2 + 20B = B ^ 2 + 20
Print " Values in Subroutine After CalculationsPrint " Values in Subroutine After Calculations:":"
Print "A=" ; A; " B=" ; BPrint "A=" ; A; " B=" ; B
End SubEnd Sub
Before Calling : A = 12 B = 10Before Calling : A = 12 B = 10
Values in Subroutine Before Any CalculationValues in Subroutine Before Any Calculation::
A = 12 B = 10A = 12 B = 10
Values in Subroutine After CalculationValues in Subroutine After Calculation::
A = 30 B = 120A = 30 B = 120
After Calling: A = 30 B = 120After Calling: A = 30 B = 120
•DefaultDefault
•AA((((By ValBy Val..
•
–
–By ReferenceBy Reference
•OptionalOptionalParametersParameters
a. Private Sub ex1a. Private Sub ex1 ( x As Integer, Optional Y As Integar( x As Integer, Optional Y As Integar(.(.
b. Private Sub ex2b. Private Sub ex2 (Optional A As Integer, Optional B As Integer, Optional C As Integer(Optional A As Integer, Optional B As Integer, Optional C As Integer(.(.
Call ex1(10Call ex1(10((
1010XXYY((
Call ex1(10, 12Call ex1(10, 12((
1010XX1212YY((
e x 2e x 2
Call ex2Call ex2
C, B, AC, B, A((
Call ex2( ,15, 40Call ex2( ,15, 40((
AA1515BB4040CC((
Call ex2 ( , , 40Call ex2 ( , , 40((
AABB4040CC((
::
Private Sub CalculatePrivate Sub Calculate( (( (
Call TestCall Test
Call test(5Call test(5((
Call Test(5,12Call Test(5,12((
Call Test(5,12,3Call Test(5,12,3((
Call Test( ,12Call Test( ,12((
Call Test( , ,3Call Test( , ,3((
End SubEnd Sub
Private Sub TestPrivate Sub Test (Optional A As Integer = 50, Optional B As Integer= 15(Optional A As Integer = 50, Optional B As Integer= 15,,
Optional Z As Integer = 20Optional Z As Integer = 20((
Dim Sum As Integer, Product As IntegerDim Sum As Integer, Product As Integer
Sum = A + B + CSum = A + B + C
Product = A*B*CProduct = A*B*C
Print "A= "; A; "B= " ; B; "C="; CPrint "A= "; A; "B= " ; B; "C="; C
Print "Sum of A, B, and C= "; SumPrint "Sum of A, B, and C= "; Sum
Print " Product of ' A' B and C =" ; ProductPrint " Product of ' A' B and C =" ; Product
End SubEnd Sub
Exit Sub and Exit FunctionExit Sub and Exit Function((
•VB6VB6Exit SubExit SubSubSub((End SubEnd Sub.(.(
•Exit FunctionExit FunctionFunctionFunctionEnd FunctionEnd Function.(.(
•
•DimDim
Dim A As IntegerDim A As Integer
Dim Sum As Integer, Auerage As RealDim Sum As Integer, Auerage As Real
•Average, Sum, AAverage, Sum, A
End SubEnd SubEnd FunctionEnd Function
StaticStaticDimDim
Static Dim X As Integer, Y As RealStatic Dim X As Integer, Y As Real
Static W As StringStatic W As String
•W, Y, XW, Y, XProjectProject
•DefaultDefaultStaticStatic
Private Static Sub Find( )Private Static Sub Find( )
Dim X As Integer, Y As RealDim X As Integer, Y As Real
..
..
End SubEnd Sub
Local ScopeLocal Scope:(:(
End SubEnd Sub.(.(
Private ScopePrivate Scope:(:(
Module ScopeModule ScopePrivatePrivateFormFormProjectProject
Public ScopePublic Scope:(:(
PublicPublicProjectProject
RecursionRecursion((
•VB6VB6
•nnnn
n ! = n * (n – 1) * (n – 2) * ..... * 2 * 1n ! = n * (n – 1) * (n – 2) * ..... * 2 * 1
n ! = n * (n – 1) ! (Recursive Stepn ! = n * (n – 1) ! (Recursive Step((
11! =! =O (Basis StepO (Basis Step((
nn
Private Function RecFact (n As Integer) As LongPrivate Function RecFact (n As Integer) As Long
If n < = 1 ThenIf n < = 1 Then
RecFact = 1RecFact = 1
ElseElse
RectFact = n * RectFact (n – 1)RectFact = n * RectFact (n – 1)
End IfEnd If
End FunctionEnd Function
Code ModulesCode Modules((
•VB6VB6GUIGUI
•Standard ModulesStandard Modules
•
•Default ScopeDefault ScopePrivatePrivatePrivatePrivatePublicPublic
ملخص البرمجة المرئية - الوحدة الخامسة

More Related Content

What's hot

c-programming-using-pointers
c-programming-using-pointersc-programming-using-pointers
c-programming-using-pointersSushil Mishra
 
Machine-level Composition of Modularized Crosscutting Concerns
Machine-level Composition of Modularized Crosscutting ConcernsMachine-level Composition of Modularized Crosscutting Concerns
Machine-level Composition of Modularized Crosscutting Concernssaintiss
 
Tweaking the interactive grid
Tweaking the interactive gridTweaking the interactive grid
Tweaking the interactive gridRoel Hartman
 
Method C# - Lec8 (Workshop on C# Programming: Learn to Build)
Method C# - Lec8 (Workshop on C# Programming: Learn to Build)Method C# - Lec8 (Workshop on C# Programming: Learn to Build)
Method C# - Lec8 (Workshop on C# Programming: Learn to Build)Jannat Ruma
 
Blending Culture in Twitter Client
Blending Culture in Twitter ClientBlending Culture in Twitter Client
Blending Culture in Twitter ClientKenji Tanaka
 
Score (smart contract for icon)
Score (smart contract for icon) Score (smart contract for icon)
Score (smart contract for icon) Doyun Hwang
 
Basic program in java
Basic program in java Basic program in java
Basic program in java Sudeep Singh
 
The Ring programming language version 1.5.4 book - Part 77 of 185
The Ring programming language version 1.5.4 book - Part 77 of 185The Ring programming language version 1.5.4 book - Part 77 of 185
The Ring programming language version 1.5.4 book - Part 77 of 185Mahmoud Samir Fayed
 
project report in C++ programming and SQL
project report in C++ programming and SQLproject report in C++ programming and SQL
project report in C++ programming and SQLvikram mahendra
 

What's hot (20)

c-programming-using-pointers
c-programming-using-pointersc-programming-using-pointers
c-programming-using-pointers
 
Machine-level Composition of Modularized Crosscutting Concerns
Machine-level Composition of Modularized Crosscutting ConcernsMachine-level Composition of Modularized Crosscutting Concerns
Machine-level Composition of Modularized Crosscutting Concerns
 
Pratik Bakane C++
Pratik Bakane C++Pratik Bakane C++
Pratik Bakane C++
 
Tweaking the interactive grid
Tweaking the interactive gridTweaking the interactive grid
Tweaking the interactive grid
 
C sharp 8
C sharp 8C sharp 8
C sharp 8
 
Method C# - Lec8 (Workshop on C# Programming: Learn to Build)
Method C# - Lec8 (Workshop on C# Programming: Learn to Build)Method C# - Lec8 (Workshop on C# Programming: Learn to Build)
Method C# - Lec8 (Workshop on C# Programming: Learn to Build)
 
C++ programs
C++ programsC++ programs
C++ programs
 
C++ TUTORIAL 4
C++ TUTORIAL 4C++ TUTORIAL 4
C++ TUTORIAL 4
 
Blending Culture in Twitter Client
Blending Culture in Twitter ClientBlending Culture in Twitter Client
Blending Culture in Twitter Client
 
Pratik Bakane C++
Pratik Bakane C++Pratik Bakane C++
Pratik Bakane C++
 
Pratik Bakane C++
Pratik Bakane C++Pratik Bakane C++
Pratik Bakane C++
 
Chapter 5
Chapter 5Chapter 5
Chapter 5
 
Score (smart contract for icon)
Score (smart contract for icon) Score (smart contract for icon)
Score (smart contract for icon)
 
Vdtonline
VdtonlineVdtonline
Vdtonline
 
C lab programs
C lab programsC lab programs
C lab programs
 
Basic program in java
Basic program in java Basic program in java
Basic program in java
 
The Ring programming language version 1.5.4 book - Part 77 of 185
The Ring programming language version 1.5.4 book - Part 77 of 185The Ring programming language version 1.5.4 book - Part 77 of 185
The Ring programming language version 1.5.4 book - Part 77 of 185
 
DataStructures notes
DataStructures notesDataStructures notes
DataStructures notes
 
Java programs
Java programsJava programs
Java programs
 
project report in C++ programming and SQL
project report in C++ programming and SQLproject report in C++ programming and SQL
project report in C++ programming and SQL
 

Viewers also liked

Viewers also liked (6)

ملخص البرمجة المرئية - الوحدة العاشرة
ملخص البرمجة المرئية - الوحدة العاشرةملخص البرمجة المرئية - الوحدة العاشرة
ملخص البرمجة المرئية - الوحدة العاشرة
 
ملخص البرمجة المرئية - الوحدة الرابعة
ملخص البرمجة المرئية - الوحدة الرابعةملخص البرمجة المرئية - الوحدة الرابعة
ملخص البرمجة المرئية - الوحدة الرابعة
 
ملخص البرمجة المرئية - الوحدة التاسعة
ملخص البرمجة المرئية - الوحدة التاسعةملخص البرمجة المرئية - الوحدة التاسعة
ملخص البرمجة المرئية - الوحدة التاسعة
 
ملخص البرمجة المرئية - الوحدة الاولى
ملخص البرمجة المرئية - الوحدة الاولىملخص البرمجة المرئية - الوحدة الاولى
ملخص البرمجة المرئية - الوحدة الاولى
 
ملخص البرمجة المرئية - 1377
ملخص البرمجة المرئية - 1377ملخص البرمجة المرئية - 1377
ملخص البرمجة المرئية - 1377
 
ملخص البرمجة المرئية - الوحدة الثالثة
ملخص البرمجة المرئية - الوحدة الثالثةملخص البرمجة المرئية - الوحدة الثالثة
ملخص البرمجة المرئية - الوحدة الثالثة
 

Similar to ملخص البرمجة المرئية - الوحدة الخامسة

A Few of My Favorite (Python) Things
A Few of My Favorite (Python) ThingsA Few of My Favorite (Python) Things
A Few of My Favorite (Python) ThingsMichael Pirnat
 
EST 102 Programming in C-MODULE 4
EST 102 Programming in C-MODULE 4EST 102 Programming in C-MODULE 4
EST 102 Programming in C-MODULE 4NIMMYRAJU
 
constructorsfjy5ediykEASFul;IUWORHusi;gfb.pptx
constructorsfjy5ediykEASFul;IUWORHusi;gfb.pptxconstructorsfjy5ediykEASFul;IUWORHusi;gfb.pptx
constructorsfjy5ediykEASFul;IUWORHusi;gfb.pptxAshrithaRokkam
 
Solidity Security and Best Coding Practices
Solidity Security and Best Coding PracticesSolidity Security and Best Coding Practices
Solidity Security and Best Coding PracticesGene Leybzon
 
Basic VB problems
Basic VB problemsBasic VB problems
Basic VB problemsMukesh Das
 
Categories for the Working C++ Programmer
Categories for the Working C++ ProgrammerCategories for the Working C++ Programmer
Categories for the Working C++ ProgrammerPlatonov Sergey
 
ADG Poznań - Kotlin for Android developers
ADG Poznań - Kotlin for Android developersADG Poznań - Kotlin for Android developers
ADG Poznań - Kotlin for Android developersBartosz Kosarzycki
 
Manipulating Magento - Meet Magento Netherlands 2018
Manipulating Magento - Meet Magento Netherlands 2018Manipulating Magento - Meet Magento Netherlands 2018
Manipulating Magento - Meet Magento Netherlands 2018Joke Puts
 
How do you create a programming language for the JVM?
How do you create a programming language for the JVM?How do you create a programming language for the JVM?
How do you create a programming language for the JVM?Federico Tomassetti
 
2 BytesC++ course_2014_c3_ function basics&parameters and overloading
2 BytesC++ course_2014_c3_ function basics&parameters and overloading2 BytesC++ course_2014_c3_ function basics&parameters and overloading
2 BytesC++ course_2014_c3_ function basics&parameters and overloadingkinan keshkeh
 

Similar to ملخص البرمجة المرئية - الوحدة الخامسة (20)

A Few of My Favorite (Python) Things
A Few of My Favorite (Python) ThingsA Few of My Favorite (Python) Things
A Few of My Favorite (Python) Things
 
C++ Overview PPT
C++ Overview PPTC++ Overview PPT
C++ Overview PPT
 
C++
C++C++
C++
 
Functions in C
Functions in CFunctions in C
Functions in C
 
Oops Quiz
Oops QuizOops Quiz
Oops Quiz
 
Constructor
ConstructorConstructor
Constructor
 
EST 102 Programming in C-MODULE 4
EST 102 Programming in C-MODULE 4EST 102 Programming in C-MODULE 4
EST 102 Programming in C-MODULE 4
 
กลุ่ม6
กลุ่ม6กลุ่ม6
กลุ่ม6
 
constructorsfjy5ediykEASFul;IUWORHusi;gfb.pptx
constructorsfjy5ediykEASFul;IUWORHusi;gfb.pptxconstructorsfjy5ediykEASFul;IUWORHusi;gfb.pptx
constructorsfjy5ediykEASFul;IUWORHusi;gfb.pptx
 
Solidity Security and Best Coding Practices
Solidity Security and Best Coding PracticesSolidity Security and Best Coding Practices
Solidity Security and Best Coding Practices
 
Basic VB problems
Basic VB problemsBasic VB problems
Basic VB problems
 
L4 functions
L4 functionsL4 functions
L4 functions
 
Categories for the Working C++ Programmer
Categories for the Working C++ ProgrammerCategories for the Working C++ Programmer
Categories for the Working C++ Programmer
 
ADG Poznań - Kotlin for Android developers
ADG Poznań - Kotlin for Android developersADG Poznań - Kotlin for Android developers
ADG Poznań - Kotlin for Android developers
 
Function (rule in programming)
Function (rule in programming)Function (rule in programming)
Function (rule in programming)
 
Manipulating Magento - Meet Magento Netherlands 2018
Manipulating Magento - Meet Magento Netherlands 2018Manipulating Magento - Meet Magento Netherlands 2018
Manipulating Magento - Meet Magento Netherlands 2018
 
How do you create a programming language for the JVM?
How do you create a programming language for the JVM?How do you create a programming language for the JVM?
How do you create a programming language for the JVM?
 
Python crush course
Python crush coursePython crush course
Python crush course
 
2 BytesC++ course_2014_c3_ function basics&parameters and overloading
2 BytesC++ course_2014_c3_ function basics&parameters and overloading2 BytesC++ course_2014_c3_ function basics&parameters and overloading
2 BytesC++ course_2014_c3_ function basics&parameters and overloading
 
unit_2 (1).pptx
unit_2 (1).pptxunit_2 (1).pptx
unit_2 (1).pptx
 

More from جامعة القدس المفتوحة

كتاب: Simply AVR مقدمة مبسطة عن النظم المدمجة
كتاب: Simply AVR مقدمة مبسطة عن النظم المدمجةكتاب: Simply AVR مقدمة مبسطة عن النظم المدمجة
كتاب: Simply AVR مقدمة مبسطة عن النظم المدمجةجامعة القدس المفتوحة
 
ملخص تحليل الانظمة وتصميمها - الوحدة السادسة
ملخص تحليل الانظمة وتصميمها - الوحدة السادسةملخص تحليل الانظمة وتصميمها - الوحدة السادسة
ملخص تحليل الانظمة وتصميمها - الوحدة السادسةجامعة القدس المفتوحة
 
ملخص تحليل الانظمة وتصميمها - الوحدة الخامسة
ملخص تحليل الانظمة وتصميمها - الوحدة الخامسةملخص تحليل الانظمة وتصميمها - الوحدة الخامسة
ملخص تحليل الانظمة وتصميمها - الوحدة الخامسةجامعة القدس المفتوحة
 
ملخص تحليل الانظمة وتصميمها - الوحدة الثالثة
ملخص تحليل الانظمة وتصميمها - الوحدة الثالثةملخص تحليل الانظمة وتصميمها - الوحدة الثالثة
ملخص تحليل الانظمة وتصميمها - الوحدة الثالثةجامعة القدس المفتوحة
 
ملخص تحليل الانظمة وتصميمها - الوحدة الثامنة
ملخص تحليل الانظمة وتصميمها - الوحدة الثامنةملخص تحليل الانظمة وتصميمها - الوحدة الثامنة
ملخص تحليل الانظمة وتصميمها - الوحدة الثامنةجامعة القدس المفتوحة
 
ملخص تحليل الانظمة وتصميمها - الوحدة السابعة
ملخص تحليل الانظمة وتصميمها - الوحدة السابعةملخص تحليل الانظمة وتصميمها - الوحدة السابعة
ملخص تحليل الانظمة وتصميمها - الوحدة السابعةجامعة القدس المفتوحة
 
ملخص تحليل الانظمة وتصميمها - الوحدة الرابعة
ملخص تحليل الانظمة وتصميمها - الوحدة الرابعةملخص تحليل الانظمة وتصميمها - الوحدة الرابعة
ملخص تحليل الانظمة وتصميمها - الوحدة الرابعةجامعة القدس المفتوحة
 
ملخص تحليل الانظمة وتصميمها - الوحدة التاسعة
ملخص تحليل الانظمة وتصميمها - الوحدة التاسعةملخص تحليل الانظمة وتصميمها - الوحدة التاسعة
ملخص تحليل الانظمة وتصميمها - الوحدة التاسعةجامعة القدس المفتوحة
 
ملخص تحليل الانظمة وتصميمها - الوحدة الثانية
ملخص تحليل الانظمة وتصميمها - الوحدة الثانيةملخص تحليل الانظمة وتصميمها - الوحدة الثانية
ملخص تحليل الانظمة وتصميمها - الوحدة الثانيةجامعة القدس المفتوحة
 
ملخص تقنية تصميم صفحات الويب - الوحدة السادسة
ملخص تقنية تصميم صفحات الويب - الوحدة السادسةملخص تقنية تصميم صفحات الويب - الوحدة السادسة
ملخص تقنية تصميم صفحات الويب - الوحدة السادسةجامعة القدس المفتوحة
 
ملخص تقنية تصميم صفحات الويب - الوحدة الخامسة
ملخص تقنية تصميم صفحات الويب - الوحدة الخامسةملخص تقنية تصميم صفحات الويب - الوحدة الخامسة
ملخص تقنية تصميم صفحات الويب - الوحدة الخامسةجامعة القدس المفتوحة
 
اسئلة نهائية لمقرر تقنية تصميم صفحات الويب - 1266
اسئلة نهائية لمقرر تقنية تصميم صفحات الويب - 1266اسئلة نهائية لمقرر تقنية تصميم صفحات الويب - 1266
اسئلة نهائية لمقرر تقنية تصميم صفحات الويب - 1266جامعة القدس المفتوحة
 
مناهج البحث العلمي - اللقاء الافتراضي الثاني
مناهج البحث العلمي - اللقاء الافتراضي الثانيمناهج البحث العلمي - اللقاء الافتراضي الثاني
مناهج البحث العلمي - اللقاء الافتراضي الثانيجامعة القدس المفتوحة
 
مناهج البحث العلمي - اللقاء الافتراضي الاول
مناهج البحث العلمي - اللقاء الافتراضي الاولمناهج البحث العلمي - اللقاء الافتراضي الاول
مناهج البحث العلمي - اللقاء الافتراضي الاولجامعة القدس المفتوحة
 

More from جامعة القدس المفتوحة (20)

كتاب ميكروبيديا Micropedia
كتاب ميكروبيديا Micropediaكتاب ميكروبيديا Micropedia
كتاب ميكروبيديا Micropedia
 
كتاب: Simply AVR مقدمة مبسطة عن النظم المدمجة
كتاب: Simply AVR مقدمة مبسطة عن النظم المدمجةكتاب: Simply AVR مقدمة مبسطة عن النظم المدمجة
كتاب: Simply AVR مقدمة مبسطة عن النظم المدمجة
 
ملخص تحليل الانظمة وتصميمها - النصفي
ملخص تحليل الانظمة وتصميمها - النصفيملخص تحليل الانظمة وتصميمها - النصفي
ملخص تحليل الانظمة وتصميمها - النصفي
 
ملخص تحليل الانظمة وتصميمها - الوحدة السادسة
ملخص تحليل الانظمة وتصميمها - الوحدة السادسةملخص تحليل الانظمة وتصميمها - الوحدة السادسة
ملخص تحليل الانظمة وتصميمها - الوحدة السادسة
 
ملخص تحليل الانظمة وتصميمها - الوحدة الخامسة
ملخص تحليل الانظمة وتصميمها - الوحدة الخامسةملخص تحليل الانظمة وتصميمها - الوحدة الخامسة
ملخص تحليل الانظمة وتصميمها - الوحدة الخامسة
 
ملخص تحليل الانظمة وتصميمها - الوحدة الثالثة
ملخص تحليل الانظمة وتصميمها - الوحدة الثالثةملخص تحليل الانظمة وتصميمها - الوحدة الثالثة
ملخص تحليل الانظمة وتصميمها - الوحدة الثالثة
 
ملخص تحليل الانظمة وتصميمها - الوحدة الثامنة
ملخص تحليل الانظمة وتصميمها - الوحدة الثامنةملخص تحليل الانظمة وتصميمها - الوحدة الثامنة
ملخص تحليل الانظمة وتصميمها - الوحدة الثامنة
 
ملخص تحليل الانظمة وتصميمها - الوحدة السابعة
ملخص تحليل الانظمة وتصميمها - الوحدة السابعةملخص تحليل الانظمة وتصميمها - الوحدة السابعة
ملخص تحليل الانظمة وتصميمها - الوحدة السابعة
 
ملخص تحليل الانظمة وتصميمها - الوحدة الرابعة
ملخص تحليل الانظمة وتصميمها - الوحدة الرابعةملخص تحليل الانظمة وتصميمها - الوحدة الرابعة
ملخص تحليل الانظمة وتصميمها - الوحدة الرابعة
 
ملخص تحليل الانظمة وتصميمها - الوحدة التاسعة
ملخص تحليل الانظمة وتصميمها - الوحدة التاسعةملخص تحليل الانظمة وتصميمها - الوحدة التاسعة
ملخص تحليل الانظمة وتصميمها - الوحدة التاسعة
 
ملخص تحليل الانظمة وتصميمها - الوحدة الثانية
ملخص تحليل الانظمة وتصميمها - الوحدة الثانيةملخص تحليل الانظمة وتصميمها - الوحدة الثانية
ملخص تحليل الانظمة وتصميمها - الوحدة الثانية
 
ملخص تقنية تصميم صفحات الويب - الوحدة السادسة
ملخص تقنية تصميم صفحات الويب - الوحدة السادسةملخص تقنية تصميم صفحات الويب - الوحدة السادسة
ملخص تقنية تصميم صفحات الويب - الوحدة السادسة
 
ملخص تقنية تصميم صفحات الويب - الوحدة الخامسة
ملخص تقنية تصميم صفحات الويب - الوحدة الخامسةملخص تقنية تصميم صفحات الويب - الوحدة الخامسة
ملخص تقنية تصميم صفحات الويب - الوحدة الخامسة
 
اسئلة نهائية لمقرر تقنية تصميم صفحات الويب - 1266
اسئلة نهائية لمقرر تقنية تصميم صفحات الويب - 1266اسئلة نهائية لمقرر تقنية تصميم صفحات الويب - 1266
اسئلة نهائية لمقرر تقنية تصميم صفحات الويب - 1266
 
مناهج البحث العلمي - اللقاء الافتراضي الثاني
مناهج البحث العلمي - اللقاء الافتراضي الثانيمناهج البحث العلمي - اللقاء الافتراضي الثاني
مناهج البحث العلمي - اللقاء الافتراضي الثاني
 
مناهج البحث العلمي - شرح الوحدات 1-5
مناهج البحث العلمي - شرح الوحدات 1-5مناهج البحث العلمي - شرح الوحدات 1-5
مناهج البحث العلمي - شرح الوحدات 1-5
 
ملخص مناهج البحث العلمي كامل
ملخص مناهج البحث العلمي كاململخص مناهج البحث العلمي كامل
ملخص مناهج البحث العلمي كامل
 
ملخص مناهج البحث العلمي
ملخص مناهج البحث العلميملخص مناهج البحث العلمي
ملخص مناهج البحث العلمي
 
مناهج البحث العلمي - اللقاء الافتراضي الاول
مناهج البحث العلمي - اللقاء الافتراضي الاولمناهج البحث العلمي - اللقاء الافتراضي الاول
مناهج البحث العلمي - اللقاء الافتراضي الاول
 
ملخص تعايش مع التكنولوجيا
ملخص تعايش مع التكنولوجياملخص تعايش مع التكنولوجيا
ملخص تعايش مع التكنولوجيا
 

Recently uploaded

DATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersDATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersSabitha Banu
 
Meghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media ComponentMeghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media ComponentInMediaRes1
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxmanuelaromero2013
 
Blooming Together_ Growing a Community Garden Worksheet.docx
Blooming Together_ Growing a Community Garden Worksheet.docxBlooming Together_ Growing a Community Garden Worksheet.docx
Blooming Together_ Growing a Community Garden Worksheet.docxUnboundStockton
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxSayali Powar
 
Full Stack Web Development Course for Beginners
Full Stack Web Development Course  for BeginnersFull Stack Web Development Course  for Beginners
Full Stack Web Development Course for BeginnersSabitha Banu
 
Roles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in PharmacovigilanceRoles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in PharmacovigilanceSamikshaHamane
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...JhezDiaz1
 
Solving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxSolving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxOH TEIK BIN
 
Final demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxFinal demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxAvyJaneVismanos
 
Types of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxTypes of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxEyham Joco
 
MICROBIOLOGY biochemical test detailed.pptx
MICROBIOLOGY biochemical test detailed.pptxMICROBIOLOGY biochemical test detailed.pptx
MICROBIOLOGY biochemical test detailed.pptxabhijeetpadhi001
 
Crayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon ACrayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon AUnboundStockton
 
Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Celine George
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfEnzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfSumit Tiwari
 

Recently uploaded (20)

DATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersDATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginners
 
Meghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media ComponentMeghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media Component
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptx
 
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
 
Blooming Together_ Growing a Community Garden Worksheet.docx
Blooming Together_ Growing a Community Garden Worksheet.docxBlooming Together_ Growing a Community Garden Worksheet.docx
Blooming Together_ Growing a Community Garden Worksheet.docx
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
 
ESSENTIAL of (CS/IT/IS) class 06 (database)
ESSENTIAL of (CS/IT/IS) class 06 (database)ESSENTIAL of (CS/IT/IS) class 06 (database)
ESSENTIAL of (CS/IT/IS) class 06 (database)
 
Full Stack Web Development Course for Beginners
Full Stack Web Development Course  for BeginnersFull Stack Web Development Course  for Beginners
Full Stack Web Development Course for Beginners
 
Roles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in PharmacovigilanceRoles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in Pharmacovigilance
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
9953330565 Low Rate Call Girls In Rohini Delhi NCR
9953330565 Low Rate Call Girls In Rohini  Delhi NCR9953330565 Low Rate Call Girls In Rohini  Delhi NCR
9953330565 Low Rate Call Girls In Rohini Delhi NCR
 
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
 
Solving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxSolving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptx
 
Final demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxFinal demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptx
 
Types of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxTypes of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptx
 
MICROBIOLOGY biochemical test detailed.pptx
MICROBIOLOGY biochemical test detailed.pptxMICROBIOLOGY biochemical test detailed.pptx
MICROBIOLOGY biochemical test detailed.pptx
 
Crayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon ACrayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon A
 
Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
 
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfEnzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
 

ملخص البرمجة المرئية - الوحدة الخامسة

  • 1.
  • 3. •EventsEvents((Key EventsKey EventsMouse EventsMouse Events •Built-in(VB6VB6VB6VB6 •User-Defined(Sub ProceduresSub ProceduresFunction ProcedureFunction Procedure
  • 4. IDEIDE:(:( •Code WindowCode WindowProject1-Form1 (CodeProject1-Form1 (Code((Add ProcedureAdd Procedure ToolsTools.. •CalculateCalculate))TypeTypeSubSubScopeScopePublicPublicOKOK •End SubEnd SubEnd FunctionEnd Function
  • 5. Sub ProceduresSub Procedures(( ]]Accessing Type] Sub Procedure Name (Parameter ListAccessing Type] Sub Procedure Name (Parameter List(( StatementsStatements End SubEnd Sub Procedure Name ( [Parameter ListProcedure Name ( [Parameter List[ ([ (
  • 6. 11:(:( Private Sub Command_ClickPrivate Sub Command_Click( )( ) Dim X, Y, Z As IntegerDim X, Y, Z As Integer X = 40X = 40 Y = 135Y = 135 Z = 90Z = 90 Max (X, Y, Z)Max (X, Y, Z) End SubEnd Sub Private Sub Max (A, B, C, As Integer)Private Sub Max (A, B, C, As Integer) Dim Answer As IntegerDim Answer As Integer Answer = AAnswer = A If B > Answer Then Answer = BIf B > Answer Then Answer = B If C > Answer Then Answer = CIf C > Answer Then Answer = C Print "Maximum Value =" ; AnswerPrint "Maximum Value =" ; Answer End SubEnd Sub
  • 7. Sub FunctionsSub Functions(( •FunctionFunctionSubSubReturn a ValueReturn a ValueTypeType.. • Private Sub Command – Click ( )Private Sub Command – Click ( ) Dim X, Y, Z, S, P As RealDim X, Y, Z, S, P As Real X = 2.8X = 2.8 Y = 12.5Y = 12.5 Z = 30.2Z = 30.2 Print "Summation of X,Y and Z =" Sum (X, Y, Z)Print "Summation of X,Y and Z =" Sum (X, Y, Z) Print "Product of X,Y, and Z = "; Prod (X, Y, Z)Print "Product of X,Y, and Z = "; Prod (X, Y, Z) End SubEnd Sub Public Function Sum (A, B, C, As double) As doublePublic Function Sum (A, B, C, As double) As double Sum = A + B + CSum = A + B + C End FunctionEnd Function Public Function Prod (A, B, C, As double) As doublePublic Function Prod (A, B, C, As double) As double Prod = A * B * CProd = A * B * C End FunctionEnd Function
  • 12. Procedure's CallingProcedure's Calling FunctionFunctionSubSubCalling StatementCalling Statement ]]Call ] Procedure Name ( [ Parameter ListCall ] Procedure Name ( [ Parameter List[ ([ ( ]]CallCall[[ Procedure NameProcedure Name ::Parameter ListParameter List
  • 13. •ParametersParameters • •11..Call By ValueCall By Value(( 22..((Call By ReferenceCall By Reference
  • 14. 11..Call By ValueCall By Value(( • • •By ValBy Val
  • 15. Call By ValueCall By Value(( Private Sub MainPrivate Sub Main( (( ( Dim A, B As IntegerDim A, B As Integer A = 12A = 12 B = 10B = 10 Print " Before Calling: A= ";A; "B= "; BPrint " Before Calling: A= ";A; "B= "; B Call Calculate ( ByVal A, ByVal BCall Calculate ( ByVal A, ByVal B(( Print "After Calling : A = ";A; "B = " ; BPrint "After Calling : A = ";A; "B = " ; B End SubEnd Sub Private Sub Calculate (A As Integer, B As Integer)Private Sub Calculate (A As Integer, B As Integer) Print "Values in Subroutine Before Any Calculations:"Print "Values in Subroutine Before Any Calculations:" Print "A= " ; A; "B ="; BPrint "A= " ; A; "B ="; B A = A + B + 8A = A + B + 8 B = B ^ 2 + 20B = B ^ 2 + 20 Print " Values in Subroutine After Calculations:"Print " Values in Subroutine After Calculations:" Print "A=" ; A; " B=" ; BPrint "A=" ; A; " B=" ; B End SubEnd Sub Before Calling: A = 12 B = 10Before Calling: A = 12 B = 10 Values in Subroutine Before Any CalculationValues in Subroutine Before Any Calculation:: A = 12 B = 10A = 12 B = 10 Values in Subroutine After CalculationValues in Subroutine After Calculation:: A = 30 B = 120A = 30 B = 120
  • 16. 22..((Call By ReferenceCall By Reference • •.. •By RefBy Ref
  • 17. Private Sub Main ( )Private Sub Main ( ) Dim A, B As IntegerDim A, B As Integer A = 12A = 12 B = 10B = 10 Print " Before Calling: A= ";A; "B= "; BPrint " Before Calling: A= ";A; "B= "; B Call Calculate ( ByRef A, ByRef B)Call Calculate ( ByRef A, ByRef B) Print "After Calling : A = ";A; "B = " ; BPrint "After Calling : A = ";A; "B = " ; B End SubEnd Sub Private Sub Calculate (A As Integer, B As IntegerPrivate Sub Calculate (A As Integer, B As Integer(( Print "Values in Subroutine Before Any CalculationsPrint "Values in Subroutine Before Any Calculations:":" Print "A= " ; A; "B ="; BPrint "A= " ; A; "B ="; B A = A + B + 8A = A + B + 8 B = B ^ 2 + 20B = B ^ 2 + 20 Print " Values in Subroutine After CalculationsPrint " Values in Subroutine After Calculations:":" Print "A=" ; A; " B=" ; BPrint "A=" ; A; " B=" ; B End SubEnd Sub Before Calling : A = 12 B = 10Before Calling : A = 12 B = 10 Values in Subroutine Before Any CalculationValues in Subroutine Before Any Calculation:: A = 12 B = 10A = 12 B = 10 Values in Subroutine After CalculationValues in Subroutine After Calculation:: A = 30 B = 120A = 30 B = 120 After Calling: A = 30 B = 120After Calling: A = 30 B = 120
  • 19. •OptionalOptionalParametersParameters a. Private Sub ex1a. Private Sub ex1 ( x As Integer, Optional Y As Integar( x As Integer, Optional Y As Integar(.(. b. Private Sub ex2b. Private Sub ex2 (Optional A As Integer, Optional B As Integer, Optional C As Integer(Optional A As Integer, Optional B As Integer, Optional C As Integer(.(. Call ex1(10Call ex1(10(( 1010XXYY(( Call ex1(10, 12Call ex1(10, 12(( 1010XX1212YY(( e x 2e x 2 Call ex2Call ex2 C, B, AC, B, A(( Call ex2( ,15, 40Call ex2( ,15, 40(( AA1515BB4040CC(( Call ex2 ( , , 40Call ex2 ( , , 40(( AABB4040CC((
  • 20. :: Private Sub CalculatePrivate Sub Calculate( (( ( Call TestCall Test Call test(5Call test(5(( Call Test(5,12Call Test(5,12(( Call Test(5,12,3Call Test(5,12,3(( Call Test( ,12Call Test( ,12(( Call Test( , ,3Call Test( , ,3(( End SubEnd Sub Private Sub TestPrivate Sub Test (Optional A As Integer = 50, Optional B As Integer= 15(Optional A As Integer = 50, Optional B As Integer= 15,, Optional Z As Integer = 20Optional Z As Integer = 20(( Dim Sum As Integer, Product As IntegerDim Sum As Integer, Product As Integer Sum = A + B + CSum = A + B + C Product = A*B*CProduct = A*B*C Print "A= "; A; "B= " ; B; "C="; CPrint "A= "; A; "B= " ; B; "C="; C Print "Sum of A, B, and C= "; SumPrint "Sum of A, B, and C= "; Sum Print " Product of ' A' B and C =" ; ProductPrint " Product of ' A' B and C =" ; Product End SubEnd Sub
  • 21. Exit Sub and Exit FunctionExit Sub and Exit Function(( •VB6VB6Exit SubExit SubSubSub((End SubEnd Sub.(.( •Exit FunctionExit FunctionFunctionFunctionEnd FunctionEnd Function.(.(
  • 22. • •DimDim Dim A As IntegerDim A As Integer Dim Sum As Integer, Auerage As RealDim Sum As Integer, Auerage As Real •Average, Sum, AAverage, Sum, A End SubEnd SubEnd FunctionEnd Function
  • 23. StaticStaticDimDim Static Dim X As Integer, Y As RealStatic Dim X As Integer, Y As Real Static W As StringStatic W As String •W, Y, XW, Y, XProjectProject •DefaultDefaultStaticStatic Private Static Sub Find( )Private Static Sub Find( ) Dim X As Integer, Y As RealDim X As Integer, Y As Real .. .. End SubEnd Sub
  • 24. Local ScopeLocal Scope:(:( End SubEnd Sub.(.( Private ScopePrivate Scope:(:( Module ScopeModule ScopePrivatePrivateFormFormProjectProject Public ScopePublic Scope:(:( PublicPublicProjectProject
  • 25. RecursionRecursion(( •VB6VB6 •nnnn n ! = n * (n – 1) * (n – 2) * ..... * 2 * 1n ! = n * (n – 1) * (n – 2) * ..... * 2 * 1 n ! = n * (n – 1) ! (Recursive Stepn ! = n * (n – 1) ! (Recursive Step(( 11! =! =O (Basis StepO (Basis Step((
  • 26. nn Private Function RecFact (n As Integer) As LongPrivate Function RecFact (n As Integer) As Long If n < = 1 ThenIf n < = 1 Then RecFact = 1RecFact = 1 ElseElse RectFact = n * RectFact (n – 1)RectFact = n * RectFact (n – 1) End IfEnd If End FunctionEnd Function
  • 27. Code ModulesCode Modules(( •VB6VB6GUIGUI •Standard ModulesStandard Modules • •Default ScopeDefault ScopePrivatePrivatePrivatePrivatePublicPublic