SlideShare a Scribd company logo
1 of 24
6
Private Sub Command1_Click()
Text3.Text = Val(Text1.Text) + Val(Text2.Text)
End Sub
Private Sub Command2_Click()
Text3.Text = Val(Text1.Text) - Val(Text2.Text)
End Sub
Private Sub Command3_Click()
Text3.Text = Val(Text1.Text) * Val(Text2.Text)
End Sub
Private Sub Command4_Click()
Text3.Text = Val(Text1.Text) / Val(Text2.Text)
End Sub
Private Sub Timer1_Timer()
Label1.Caption = Time
Label2.Caption = Date
End Sub
Label1.caption  label1  Time 
Label2.caption label2  Date 
Timer  interval  100
F5   
Timer
Type Storage Range of Values
Byte  1 byte  0 to 255 
Integer  2 bytes  -32,768 to 32,767 
Long   4 bytes  -2,147,483,648 to 2,147,483,648 
Single  4 bytes 
-3.402823E+38 to -1.401298E-45 for negative values
1.401298E-45 to 3.402823E+38 for positive values. 
Double  8 bytes 
-1.79769313486232e+308 to -4.94065645841247E-324 for negative values
4.94065645841247E-324 to 1.79769313486232e+308 for positive values. 
Currency 8 bytes  -922,337,203,685,477.5808 to 922,337,203,685,477.5807 
Decimal  12 bytes 
+/- 79,228,162,514,264,337,593,543,950,335 if no decimal is use
+/- 7.9228162514264337593543950335 (28 decimal places). 
Data Type Storage Range
String(fixed length)  Length of string  1 to 65,400 characters 
String(variable length)  Length + 10 bytes 0 to 2 billion characters 
Date  8 bytes 
January 1, 100 to December 31,
9999 
Boolean  2 bytes  True or False 
Object  4 bytes  Any embedded object 
Variant(numeric)  16 bytes  Any value as large as Double 
Variant(text)  Length+22 bytes  Same as variable-length string 
Identifier type character Data type Example
% Integer Dim L%
& Long Dim M&
@ Decimal Const W@ = 37.5
! Single Dim Q!
# Double Dim X#
$ String Dim V$ = "Secret"
12ABC
*sum
-b10
Ab.c
xyz$wv
Valid Name Invalid Name
My_Car My.Car
ThisYear 1NewBoy
Long_Name_Can_beUSE
He&HisFather *& is not
acceptable

40
Under Score
$, @,#,!,&,%PrintPrintPrintText
1: (
Variant
Comments
Single Quote‘

Value = 10 ' = ‫ةةةة‬10 Value ‫ةةة‬
‫ةةةةةةة‬ ‫ةةةةةة‬
Text1.Text = Valu '‫ةة‬ ‫ةةةةةة‬ ‫ةةة‬ ‫ة‬
‫ةةةةةةة‬ ‫ةةة‬ ‫ةةةةة‬
Dim
Dim Value As Integer
Option Explicit
Option Explicit
Option Explicit 'in Declarations section
Private Sub Command1_Click()
Dim n As Integer 'You must declare n, otherwise
n = 20 'it will show error
Print n + 1
End Sub
'Declarations section
Dim n As Integer 'n is accessible from all the procedures
____________________________________
Private Sub cmdShow1_Click)(
n = 7
Print n
End Sub
____________________________________
Private Sub cmdShow2_Click)(
Print n + 1
End Sub
Dim VariableName As DataType
Dim VariableName1 As DataType1, VariableName2 As DataType2
Dim password As String
Dim yourName As String
Dim firstnum As Integer
Dim secondnum As Integer
Dim total As Integer
Dim doDate As Date
Dim password As String, yourName As String, firstnum As Integer
Constant
Constants are different from variables in the sense that their
values do not change during the running of the program.
Const Constant Name As Data Type = Value
Const Pi As Single=3.142
Const Temp As Single=37
Const Score As Single=100
Static:Static VariablesFormModuleClassStatic
Private:General VariablesForm
Public:General Variables
Operator Mathematical function Example
^ Exponential 2^4=16
* Multiplication 4*3=12, (5*6))2=60
/ Division 12/4=3
Mod Modulus(return the remainder from an
integer division)
15 Mod 4=3 255 mod 10=5
 Integer Division(discards the decimal
places)
194=4
+ or & String concatenation "Visual"&"Basic"="Visual
Basic"
VB
1.)(
2.^
3.
4./ *
5.
6.Mod
7.- +
Private Sub cmdEnterValues_Click)(
a = Val(InputBox("Enter the value of a", "Input value"((
b = Val(InputBox("Enter the value of b", "Input value"((
MsgBox "The sum is " & a + b, vbInformation, "Output"
End Sub
Dim firstName As String
Dim secondName As String
Dim yourName As String
Private Sub Command1_Click()
firstName = Text1.Text
secondName = Text2.Text
yourName = secondName + " " + firstName
Label1.Caption = yourName
End Sub
Dim number1, number2, number3 as Integer
Dim total, average as variant
Private sub Form_Click
number1=val(Text1.Text)
number2=val(Text2.Text)
number3= val(Text3.Text)
Total=number1+number2+number3
Average=Total/3
Label1.Caption=Total
Label2.Caption=Average
End Sub
Operator Meaning
And Both sides must be true
or One side or other must be true
Xor One side or other must be true but
not both
Not Negates truth
Operator Meaning
= Equal to
> More than
< Less Than
>= More than and equal
<= Less than and equal
<> Not Equal to
ملخص البرمجة المرئية - الوحدة الثالثة

More Related Content

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

The Ring programming language version 1.5.1 book - Part 174 of 180
The Ring programming language version 1.5.1 book - Part 174 of 180 The Ring programming language version 1.5.1 book - Part 174 of 180
The Ring programming language version 1.5.1 book - Part 174 of 180 Mahmoud Samir Fayed
 
The Ring programming language version 1.9 book - Part 98 of 210
The Ring programming language version 1.9 book - Part 98 of 210The Ring programming language version 1.9 book - Part 98 of 210
The Ring programming language version 1.9 book - Part 98 of 210Mahmoud Samir Fayed
 
V design and implementation of network security using genetic algorithm
V design and implementation of network security using genetic algorithmV design and implementation of network security using genetic algorithm
V design and implementation of network security using genetic algorithmeSAT Journals
 
Design and implementation of network security using genetic algorithm
Design and implementation of network security using genetic algorithmDesign and implementation of network security using genetic algorithm
Design and implementation of network security using genetic algorithmeSAT Publishing House
 
Visual Basic Review - ICA
Visual Basic Review - ICAVisual Basic Review - ICA
Visual Basic Review - ICAemtrajano
 
Imports System.Net.Sockets Imports System.Text Public Class Form1 .pdf
  Imports System.Net.Sockets Imports System.Text Public Class Form1   .pdf  Imports System.Net.Sockets Imports System.Text Public Class Form1   .pdf
Imports System.Net.Sockets Imports System.Text Public Class Form1 .pdfapnashop1
 
Chapter 1 Class 12 Computer Science Unit 1
Chapter 1 Class 12 Computer Science Unit 1Chapter 1 Class 12 Computer Science Unit 1
Chapter 1 Class 12 Computer Science Unit 1ssusera7a08a
 
Revision of the basics of python1 (1).pdf
Revision of the basics of python1 (1).pdfRevision of the basics of python1 (1).pdf
Revision of the basics of python1 (1).pdfoptimusnotch44
 
Getting started cpp full
Getting started cpp   fullGetting started cpp   full
Getting started cpp fullVõ Hòa
 
Python functions
Python functionsPython functions
Python functionsToniyaP1
 
re:mobidyc the overview
re:mobidyc the overviewre:mobidyc the overview
re:mobidyc the overviewESUG
 
java Basic Programming Needs
java Basic Programming Needsjava Basic Programming Needs
java Basic Programming NeedsRaja Sekhar
 
Chapter 2 Python Language Basics, IPython.pptx
Chapter 2 Python Language Basics, IPython.pptxChapter 2 Python Language Basics, IPython.pptx
Chapter 2 Python Language Basics, IPython.pptxSovannDoeur
 
Visual Basic Fundamentals
Visual Basic FundamentalsVisual Basic Fundamentals
Visual Basic FundamentalsDivyaR219113
 
Raspberry Pi - Lecture 5 Python for Raspberry Pi
Raspberry Pi - Lecture 5 Python for Raspberry PiRaspberry Pi - Lecture 5 Python for Raspberry Pi
Raspberry Pi - Lecture 5 Python for Raspberry PiMohamed Abdallah
 

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

.net progrmming part4
.net progrmming part4.net progrmming part4
.net progrmming part4
 
The Ring programming language version 1.5.1 book - Part 174 of 180
The Ring programming language version 1.5.1 book - Part 174 of 180 The Ring programming language version 1.5.1 book - Part 174 of 180
The Ring programming language version 1.5.1 book - Part 174 of 180
 
Visual Basic User Interface -IV
Visual Basic User Interface -IVVisual Basic User Interface -IV
Visual Basic User Interface -IV
 
The Ring programming language version 1.9 book - Part 98 of 210
The Ring programming language version 1.9 book - Part 98 of 210The Ring programming language version 1.9 book - Part 98 of 210
The Ring programming language version 1.9 book - Part 98 of 210
 
V design and implementation of network security using genetic algorithm
V design and implementation of network security using genetic algorithmV design and implementation of network security using genetic algorithm
V design and implementation of network security using genetic algorithm
 
Design and implementation of network security using genetic algorithm
Design and implementation of network security using genetic algorithmDesign and implementation of network security using genetic algorithm
Design and implementation of network security using genetic algorithm
 
C notes for exam preparation
C notes for exam preparationC notes for exam preparation
C notes for exam preparation
 
Visual Basic Review - ICA
Visual Basic Review - ICAVisual Basic Review - ICA
Visual Basic Review - ICA
 
Functions2.pptx
Functions2.pptxFunctions2.pptx
Functions2.pptx
 
Imports System.Net.Sockets Imports System.Text Public Class Form1 .pdf
  Imports System.Net.Sockets Imports System.Text Public Class Form1   .pdf  Imports System.Net.Sockets Imports System.Text Public Class Form1   .pdf
Imports System.Net.Sockets Imports System.Text Public Class Form1 .pdf
 
Colegio municipal
Colegio municipalColegio municipal
Colegio municipal
 
Chapter 1 Class 12 Computer Science Unit 1
Chapter 1 Class 12 Computer Science Unit 1Chapter 1 Class 12 Computer Science Unit 1
Chapter 1 Class 12 Computer Science Unit 1
 
Revision of the basics of python1 (1).pdf
Revision of the basics of python1 (1).pdfRevision of the basics of python1 (1).pdf
Revision of the basics of python1 (1).pdf
 
Getting started cpp full
Getting started cpp   fullGetting started cpp   full
Getting started cpp full
 
Python functions
Python functionsPython functions
Python functions
 
re:mobidyc the overview
re:mobidyc the overviewre:mobidyc the overview
re:mobidyc the overview
 
java Basic Programming Needs
java Basic Programming Needsjava Basic Programming Needs
java Basic Programming Needs
 
Chapter 2 Python Language Basics, IPython.pptx
Chapter 2 Python Language Basics, IPython.pptxChapter 2 Python Language Basics, IPython.pptx
Chapter 2 Python Language Basics, IPython.pptx
 
Visual Basic Fundamentals
Visual Basic FundamentalsVisual Basic Fundamentals
Visual Basic Fundamentals
 
Raspberry Pi - Lecture 5 Python for Raspberry Pi
Raspberry Pi - Lecture 5 Python for Raspberry PiRaspberry Pi - Lecture 5 Python for Raspberry Pi
Raspberry Pi - Lecture 5 Python for Raspberry Pi
 

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

MICROBIOLOGY biochemical test detailed.pptx
MICROBIOLOGY biochemical test detailed.pptxMICROBIOLOGY biochemical test detailed.pptx
MICROBIOLOGY biochemical test detailed.pptxabhijeetpadhi001
 
Hierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of managementHierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of managementmkooblal
 
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
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTiammrhaywood
 
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
 
Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...jaredbarbolino94
 
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
 
EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxEPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxRaymartEstabillo3
 
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
 
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfLike-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfMr Bounab Samir
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxiammrhaywood
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Celine George
 
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
 
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
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentInMediaRes1
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdfssuser54595a
 
AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.arsicmarija21
 

Recently uploaded (20)

MICROBIOLOGY biochemical test detailed.pptx
MICROBIOLOGY biochemical test detailed.pptxMICROBIOLOGY biochemical test detailed.pptx
MICROBIOLOGY biochemical test detailed.pptx
 
Hierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of managementHierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of management
 
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
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
 
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
 
OS-operating systems- ch04 (Threads) ...
OS-operating systems- ch04 (Threads) ...OS-operating systems- ch04 (Threads) ...
OS-operating systems- ch04 (Threads) ...
 
Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...
 
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 🔝✔️✔️
 
EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxEPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
 
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
 
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfLike-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17
 
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
 
Solving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxSolving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptx
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media Component
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
 
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
 
AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.
 
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
 

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

  • 1. 6
  • 2.
  • 3. Private Sub Command1_Click() Text3.Text = Val(Text1.Text) + Val(Text2.Text) End Sub Private Sub Command2_Click() Text3.Text = Val(Text1.Text) - Val(Text2.Text) End Sub Private Sub Command3_Click() Text3.Text = Val(Text1.Text) * Val(Text2.Text) End Sub Private Sub Command4_Click() Text3.Text = Val(Text1.Text) / Val(Text2.Text) End Sub
  • 4. Private Sub Timer1_Timer() Label1.Caption = Time Label2.Caption = Date End Sub Label1.caption  label1  Time  Label2.caption label2  Date  Timer  interval  100 F5    Timer
  • 5. Type Storage Range of Values Byte  1 byte  0 to 255  Integer  2 bytes  -32,768 to 32,767  Long   4 bytes  -2,147,483,648 to 2,147,483,648  Single  4 bytes  -3.402823E+38 to -1.401298E-45 for negative values 1.401298E-45 to 3.402823E+38 for positive values.  Double  8 bytes  -1.79769313486232e+308 to -4.94065645841247E-324 for negative values 4.94065645841247E-324 to 1.79769313486232e+308 for positive values.  Currency 8 bytes  -922,337,203,685,477.5808 to 922,337,203,685,477.5807  Decimal  12 bytes  +/- 79,228,162,514,264,337,593,543,950,335 if no decimal is use +/- 7.9228162514264337593543950335 (28 decimal places). 
  • 6. Data Type Storage Range String(fixed length)  Length of string  1 to 65,400 characters  String(variable length)  Length + 10 bytes 0 to 2 billion characters  Date  8 bytes  January 1, 100 to December 31, 9999  Boolean  2 bytes  True or False  Object  4 bytes  Any embedded object  Variant(numeric)  16 bytes  Any value as large as Double  Variant(text)  Length+22 bytes  Same as variable-length string 
  • 7. Identifier type character Data type Example % Integer Dim L% & Long Dim M& @ Decimal Const W@ = 37.5 ! Single Dim Q! # Double Dim X# $ String Dim V$ = "Secret"
  • 8. 12ABC *sum -b10 Ab.c xyz$wv Valid Name Invalid Name My_Car My.Car ThisYear 1NewBoy Long_Name_Can_beUSE He&HisFather *& is not acceptable
  • 11.  Value = 10 ' = ‫ةةةة‬10 Value ‫ةةة‬ ‫ةةةةةةة‬ ‫ةةةةةة‬ Text1.Text = Valu '‫ةة‬ ‫ةةةةةة‬ ‫ةةة‬ ‫ة‬ ‫ةةةةةةة‬ ‫ةةة‬ ‫ةةةةة‬ Dim Dim Value As Integer Option Explicit
  • 12. Option Explicit Option Explicit 'in Declarations section Private Sub Command1_Click() Dim n As Integer 'You must declare n, otherwise n = 20 'it will show error Print n + 1 End Sub
  • 13. 'Declarations section Dim n As Integer 'n is accessible from all the procedures ____________________________________ Private Sub cmdShow1_Click)( n = 7 Print n End Sub ____________________________________ Private Sub cmdShow2_Click)( Print n + 1 End Sub
  • 14. Dim VariableName As DataType Dim VariableName1 As DataType1, VariableName2 As DataType2 Dim password As String Dim yourName As String Dim firstnum As Integer Dim secondnum As Integer Dim total As Integer Dim doDate As Date Dim password As String, yourName As String, firstnum As Integer
  • 15. Constant Constants are different from variables in the sense that their values do not change during the running of the program. Const Constant Name As Data Type = Value Const Pi As Single=3.142 Const Temp As Single=37 Const Score As Single=100
  • 17. Operator Mathematical function Example ^ Exponential 2^4=16 * Multiplication 4*3=12, (5*6))2=60 / Division 12/4=3 Mod Modulus(return the remainder from an integer division) 15 Mod 4=3 255 mod 10=5 Integer Division(discards the decimal places) 194=4 + or & String concatenation "Visual"&"Basic"="Visual Basic"
  • 19. Private Sub cmdEnterValues_Click)( a = Val(InputBox("Enter the value of a", "Input value"(( b = Val(InputBox("Enter the value of b", "Input value"(( MsgBox "The sum is " & a + b, vbInformation, "Output" End Sub
  • 20.
  • 21. Dim firstName As String Dim secondName As String Dim yourName As String Private Sub Command1_Click() firstName = Text1.Text secondName = Text2.Text yourName = secondName + " " + firstName Label1.Caption = yourName End Sub
  • 22. Dim number1, number2, number3 as Integer Dim total, average as variant Private sub Form_Click number1=val(Text1.Text) number2=val(Text2.Text) number3= val(Text3.Text) Total=number1+number2+number3 Average=Total/3 Label1.Caption=Total Label2.Caption=Average End Sub
  • 23. Operator Meaning And Both sides must be true or One side or other must be true Xor One side or other must be true but not both Not Negates truth Operator Meaning = Equal to > More than < Less Than >= More than and equal <= Less than and equal <> Not Equal to