SlideShare a Scribd company logo
1 of 20
JavaScript for FoxPro
    Developers
     Mike Feltman
    F1 Technologies
Who Am I?
• President F1 Technologies since 1990
• Co-author Visual FoxExpress
• Consultant
Agenda
•   Why JavaScript?
•   VFP vs. JavaScript
•   JS Basics
•   JS Syntax & VFP Concordance
•   JS OOP
•   AJAX w/ VFP
Why JavaScript?
•   Web 2.0
•   Great way to take VFP Skills to the Web
•   In demand
•   Cross-Platform
•   Relatively easy for VFP Developers to pick
    up
VFP vs. JavaScript: Runtime
             Environment
VFP                             JavaScript
 – Operating System:              – Operating System:
       • Windows                     • Windows, MAC, Linux,
      Version:                         Unix, etc.
       • VFP Compiler Version     Version:
                                     • Browser Controlled: IE,
                                       Firefox, Opera, Safari,
                                       etc.
                                     • 1.5 current “standard”
VFP vs. JavaScript: Development
           Environment
VFP                               JavaScript
  – Designers: Editor, Form          – Designers: n/a, Requires 3rd
    Class Designer, Report             Party tools. No definitive
    Write, Class Browser, etc.         IDE
    built-in.                        – Debugger: virtually nothing
  – Debugger: Integrated               native. Varies by browser,
    debugger, with Trace,              Firebug for Firefox and
    Watch, Locals, Output, Call        Debugbar for IE.
    Stack                            – JavaScript Console various
  – Command Window                     other Command Window
                                       like utilities.
VFP vs. JavaScript: Capabilities
VFP                          JavaScript
 – Access to File System       – No File System
 – Database Engine               Access
 – Network access              – Can’t read or write to
   limited only by network       files on server
   security                    – Can’t read or write to
                                 files on client
                               – No network access
                               – Cannot access pages
                                 on another domain
VFP vs. JavaScript: Language
            Features
VFP                      JavaScript
 – Dynamically Typed       –   Dynamically Typed
 – Case Insensitive        –   Case Sensitive
 – “Second Class”          –   First Class Functions
   Functions               –   Nested Functions
 – No Nested Functions     –   Interpreted
 – Compiled or             –   OOP: Prototype based
   Interpreted             –   “0 based”
 – OOP: Class Based
 – “1 based”
Syntax
VFP                     JavaScript
 – Line Terminator:       – Line Terminator: semi-
   carriage return          colon
 – Line Continuation:     – Line Continuation: n/a
   semi-colon
Math Operators
Function         VFP     JavaScript
Addition         +       +
Subtraction      -       -
Multiplication   *       *
Division         /       /
Modulus          MOD()   %
Unary addition   x=x+1   x++
Unary            x=x-1   x--
subtraction
Assignment Operators
Function         VFP   JavaScript
Equality         =     =
Addition         n/a   +=

Subtraction      n/a   -=
Multiplication   n/a   *=
Division         n/a   /=
Modulus          n/a   %=
Comparison Operators
Function         VFP         JavaScript
Equality         =,==        ==
Greater than     >, >=       >, >=
Less Than        <, <=       <, <=
Identical & of   n/a         ===
Same Type
Not Identical    !=,!==,<>   !==
Inline IF        IIF()       (condition)?true
                             value: false
                             value
Logical Operators
Function      VFP        JavaScript
And           AND        &&
Or            OR         ||


Not           NOT, !     !
Constructs: If
VFP:                     JavaScript:
IF                       if (logical expression)
   statement(s)          {statement(s)}
ELSE                     else if (logical
   statement(s)              expression)
ENDIF                    {statements}
                         else
                         {statement(s)}
Constructs: While
VFP                    JavaScript
 DO WHILE expression     while (expression)
  statements             {
 ENDDO
                             statements
                         }

 EXIT                  break
 LOOP                  continue
Constructs: For
VFP                      JavaScript
 FOR var = n to n STEP n   for
  statements               (var=startvalue;var<=
 ENDFOR                    endvalue;var=var+inc
                           rement)
                           {
                               statements
                           }
Object Model
Event Model
Forms
3 Party
 rd

More Related Content

What's hot

Natureza, propriedades e qualidades dos fluidos: ESDE, programa complementar,...
Natureza, propriedades e qualidades dos fluidos: ESDE, programa complementar,...Natureza, propriedades e qualidades dos fluidos: ESDE, programa complementar,...
Natureza, propriedades e qualidades dos fluidos: ESDE, programa complementar,...Núcleo de Promoção Humana Vinha de Luz
 
Educação espírita para a infância
Educação espírita para a infânciaEducação espírita para a infância
Educação espírita para a infânciaDalila Melo
 
Palestra sobre capitulo x do evangelho segundo o espiritismo
Palestra sobre capitulo x do evangelho segundo o espiritismoPalestra sobre capitulo x do evangelho segundo o espiritismo
Palestra sobre capitulo x do evangelho segundo o espiritismoPaulo Farias
 
Analise do-pai-nosso
Analise do-pai-nossoAnalise do-pai-nosso
Analise do-pai-nossoAlcides
 
Pensamento benévolo
Pensamento benévoloPensamento benévolo
Pensamento benévoloGraça Maciel
 
Mediunidade e Obsessão na Infância
Mediunidade e Obsessão na InfânciaMediunidade e Obsessão na Infância
Mediunidade e Obsessão na InfânciaArlete Laenzlinger
 
4.1.1 - Felicidade e infelicidade relativas.pptx
4.1.1 - Felicidade e infelicidade relativas.pptx4.1.1 - Felicidade e infelicidade relativas.pptx
4.1.1 - Felicidade e infelicidade relativas.pptxMarta Gomes
 
Humildade - A primeira virtude
Humildade - A primeira virtudeHumildade - A primeira virtude
Humildade - A primeira virtudeRicardo Azevedo
 
Porque melindramos
Porque melindramos Porque melindramos
Porque melindramos Lisete B.
 
Obsessão , prevenção, tratamento e cura (Leonardo Pereira).
Obsessão , prevenção, tratamento e cura (Leonardo Pereira). Obsessão , prevenção, tratamento e cura (Leonardo Pereira).
Obsessão , prevenção, tratamento e cura (Leonardo Pereira). Leonardo Pereira
 
Da Lei de Reprodução
Da Lei de ReproduçãoDa Lei de Reprodução
Da Lei de Reproduçãohome
 
Evangeliza - Terra - Planeta de Provas e Expiações
Evangeliza - Terra - Planeta de Provas e ExpiaçõesEvangeliza - Terra - Planeta de Provas e Expiações
Evangeliza - Terra - Planeta de Provas e ExpiaçõesAntonino Silva
 
As curas de jesus
As curas de jesusAs curas de jesus
As curas de jesusLisete B.
 

What's hot (20)

Natureza, propriedades e qualidades dos fluidos: ESDE, programa complementar,...
Natureza, propriedades e qualidades dos fluidos: ESDE, programa complementar,...Natureza, propriedades e qualidades dos fluidos: ESDE, programa complementar,...
Natureza, propriedades e qualidades dos fluidos: ESDE, programa complementar,...
 
Educação espírita para a infância
Educação espírita para a infânciaEducação espírita para a infância
Educação espírita para a infância
 
Palestra sobre capitulo x do evangelho segundo o espiritismo
Palestra sobre capitulo x do evangelho segundo o espiritismoPalestra sobre capitulo x do evangelho segundo o espiritismo
Palestra sobre capitulo x do evangelho segundo o espiritismo
 
Analise do-pai-nosso
Analise do-pai-nossoAnalise do-pai-nosso
Analise do-pai-nosso
 
Pensamento benévolo
Pensamento benévoloPensamento benévolo
Pensamento benévolo
 
Laravel
LaravelLaravel
Laravel
 
Mediunidade e Obsessão na Infância
Mediunidade e Obsessão na InfânciaMediunidade e Obsessão na Infância
Mediunidade e Obsessão na Infância
 
4.1.1 - Felicidade e infelicidade relativas.pptx
4.1.1 - Felicidade e infelicidade relativas.pptx4.1.1 - Felicidade e infelicidade relativas.pptx
4.1.1 - Felicidade e infelicidade relativas.pptx
 
Humildade - A primeira virtude
Humildade - A primeira virtudeHumildade - A primeira virtude
Humildade - A primeira virtude
 
Conviver é preciso
Conviver é precisoConviver é preciso
Conviver é preciso
 
Porque melindramos
Porque melindramos Porque melindramos
Porque melindramos
 
Obsessão , prevenção, tratamento e cura (Leonardo Pereira).
Obsessão , prevenção, tratamento e cura (Leonardo Pereira). Obsessão , prevenção, tratamento e cura (Leonardo Pereira).
Obsessão , prevenção, tratamento e cura (Leonardo Pereira).
 
Aula Lei de reprodução - Espiritismo
Aula Lei de reprodução - EspiritismoAula Lei de reprodução - Espiritismo
Aula Lei de reprodução - Espiritismo
 
Da Lei de Reprodução
Da Lei de ReproduçãoDa Lei de Reprodução
Da Lei de Reprodução
 
Felicidade sem Culpa
Felicidade sem CulpaFelicidade sem Culpa
Felicidade sem Culpa
 
Aula M2 - Como se divertir sem se prejudicar
Aula M2 - Como se divertir sem se prejudicarAula M2 - Como se divertir sem se prejudicar
Aula M2 - Como se divertir sem se prejudicar
 
O Poder da Boa Vontade
O Poder da Boa VontadeO Poder da Boa Vontade
O Poder da Boa Vontade
 
O sacrificio mais agradavel
O sacrificio mais agradavelO sacrificio mais agradavel
O sacrificio mais agradavel
 
Evangeliza - Terra - Planeta de Provas e Expiações
Evangeliza - Terra - Planeta de Provas e ExpiaçõesEvangeliza - Terra - Planeta de Provas e Expiações
Evangeliza - Terra - Planeta de Provas e Expiações
 
As curas de jesus
As curas de jesusAs curas de jesus
As curas de jesus
 

Similar to JavaScript for FoxPro Developers: An Introduction to JavaScript Syntax and Features for Visual FoxPro Developers

In Pursuit of the Holy Grail: Building Isomorphic JavaScript Apps
In Pursuit of the Holy Grail: Building Isomorphic JavaScript AppsIn Pursuit of the Holy Grail: Building Isomorphic JavaScript Apps
In Pursuit of the Holy Grail: Building Isomorphic JavaScript AppsSpike Brehm
 
Phalcon / Zephir Introduction at PHPConfTW2013
Phalcon / Zephir Introduction at PHPConfTW2013Phalcon / Zephir Introduction at PHPConfTW2013
Phalcon / Zephir Introduction at PHPConfTW2013Rack Lin
 
DLW Europe - JavaScript Tooling
DLW Europe - JavaScript ToolingDLW Europe - JavaScript Tooling
DLW Europe - JavaScript ToolingFabian Jakobs
 
Modern Frontend Technology
Modern Frontend TechnologyModern Frontend Technology
Modern Frontend TechnologyShip Hsu
 
Intro to Functional Programming
Intro to Functional ProgrammingIntro to Functional Programming
Intro to Functional ProgrammingJordan Parmer
 
WDB005.1 - JavaScript for Java Developers (Lecture 1)
WDB005.1 - JavaScript for Java Developers (Lecture 1)WDB005.1 - JavaScript for Java Developers (Lecture 1)
WDB005.1 - JavaScript for Java Developers (Lecture 1)Igor Khotin
 
Kann JavaScript elegant sein?
Kann JavaScript elegant sein?Kann JavaScript elegant sein?
Kann JavaScript elegant sein?jbandi
 
Using Aspects for Language Portability (SCAM 2010)
Using Aspects for Language Portability (SCAM 2010)Using Aspects for Language Portability (SCAM 2010)
Using Aspects for Language Portability (SCAM 2010)lennartkats
 
General Assembly Workshop: Advanced JavaScript
General Assembly Workshop: Advanced JavaScriptGeneral Assembly Workshop: Advanced JavaScript
General Assembly Workshop: Advanced JavaScriptSpike Brehm
 
Structured web apps
Structured web appsStructured web apps
Structured web appsSheng Tian
 
DevSecCon London 2017: zap scripting workshop by Simon Bennetts
DevSecCon London 2017: zap scripting workshop by Simon BennettsDevSecCon London 2017: zap scripting workshop by Simon Bennetts
DevSecCon London 2017: zap scripting workshop by Simon BennettsDevSecCon
 
2017 DevSecCon ZAP Scripting Workshop
2017 DevSecCon ZAP Scripting Workshop2017 DevSecCon ZAP Scripting Workshop
2017 DevSecCon ZAP Scripting WorkshopSimon Bennetts
 
Bitter Java, Sweeten with JRuby
Bitter Java, Sweeten with JRubyBitter Java, Sweeten with JRuby
Bitter Java, Sweeten with JRubyBrian Sam-Bodden
 

Similar to JavaScript for FoxPro Developers: An Introduction to JavaScript Syntax and Features for Visual FoxPro Developers (20)

Feltman js4 vfp
Feltman js4 vfpFeltman js4 vfp
Feltman js4 vfp
 
In Pursuit of the Holy Grail: Building Isomorphic JavaScript Apps
In Pursuit of the Holy Grail: Building Isomorphic JavaScript AppsIn Pursuit of the Holy Grail: Building Isomorphic JavaScript Apps
In Pursuit of the Holy Grail: Building Isomorphic JavaScript Apps
 
Phalcon / Zephir Introduction at PHPConfTW2013
Phalcon / Zephir Introduction at PHPConfTW2013Phalcon / Zephir Introduction at PHPConfTW2013
Phalcon / Zephir Introduction at PHPConfTW2013
 
DLW Europe - JavaScript Tooling
DLW Europe - JavaScript ToolingDLW Europe - JavaScript Tooling
DLW Europe - JavaScript Tooling
 
slides-students-C03.pdf
slides-students-C03.pdfslides-students-C03.pdf
slides-students-C03.pdf
 
FunScript: Why bother?
FunScript: Why bother?FunScript: Why bother?
FunScript: Why bother?
 
Modern Frontend Technology
Modern Frontend TechnologyModern Frontend Technology
Modern Frontend Technology
 
Intro to Functional Programming
Intro to Functional ProgrammingIntro to Functional Programming
Intro to Functional Programming
 
WDB005.1 - JavaScript for Java Developers (Lecture 1)
WDB005.1 - JavaScript for Java Developers (Lecture 1)WDB005.1 - JavaScript for Java Developers (Lecture 1)
WDB005.1 - JavaScript for Java Developers (Lecture 1)
 
Kann JavaScript elegant sein?
Kann JavaScript elegant sein?Kann JavaScript elegant sein?
Kann JavaScript elegant sein?
 
Using Aspects for Language Portability (SCAM 2010)
Using Aspects for Language Portability (SCAM 2010)Using Aspects for Language Portability (SCAM 2010)
Using Aspects for Language Portability (SCAM 2010)
 
General Assembly Workshop: Advanced JavaScript
General Assembly Workshop: Advanced JavaScriptGeneral Assembly Workshop: Advanced JavaScript
General Assembly Workshop: Advanced JavaScript
 
Laravel level 0 (introduction)
Laravel level 0 (introduction)Laravel level 0 (introduction)
Laravel level 0 (introduction)
 
TypeScript
TypeScriptTypeScript
TypeScript
 
Structured web apps
Structured web appsStructured web apps
Structured web apps
 
Difference between php and node
Difference between php and nodeDifference between php and node
Difference between php and node
 
DevSecCon London 2017: zap scripting workshop by Simon Bennetts
DevSecCon London 2017: zap scripting workshop by Simon BennettsDevSecCon London 2017: zap scripting workshop by Simon Bennetts
DevSecCon London 2017: zap scripting workshop by Simon Bennetts
 
2017 DevSecCon ZAP Scripting Workshop
2017 DevSecCon ZAP Scripting Workshop2017 DevSecCon ZAP Scripting Workshop
2017 DevSecCon ZAP Scripting Workshop
 
Bitter Java, Sweeten with JRuby
Bitter Java, Sweeten with JRubyBitter Java, Sweeten with JRuby
Bitter Java, Sweeten with JRuby
 
Java 8 Lambda
Java 8 LambdaJava 8 Lambda
Java 8 Lambda
 

More from Mike Feltman

Feltman collections
Feltman collectionsFeltman collections
Feltman collectionsMike Feltman
 
N tier web applications
N tier web applicationsN tier web applications
N tier web applicationsMike Feltman
 
What’s new in x case 8
What’s new in x case 8What’s new in x case 8
What’s new in x case 8Mike Feltman
 
Html for desktop applications
Html for desktop applicationsHtml for desktop applications
Html for desktop applicationsMike Feltman
 
Html and visual fox pro
Html and visual fox proHtml and visual fox pro
Html and visual fox proMike Feltman
 
Error handling in visual fox pro 9
Error handling in visual fox pro 9Error handling in visual fox pro 9
Error handling in visual fox pro 9Mike Feltman
 
Docking from a z in visual fox pro 9
Docking from a z in visual fox pro 9Docking from a z in visual fox pro 9
Docking from a z in visual fox pro 9Mike Feltman
 
Introduction to afp
Introduction to afpIntroduction to afp
Introduction to afpMike Feltman
 
Where do you want to go today 2007
Where do you want to go today   2007Where do you want to go today   2007
Where do you want to go today 2007Mike Feltman
 
Where do you want to go today
Where do you want to go todayWhere do you want to go today
Where do you want to go todayMike Feltman
 

More from Mike Feltman (14)

Drop acid
Drop acidDrop acid
Drop acid
 
Feltman collections
Feltman collectionsFeltman collections
Feltman collections
 
N tier web applications
N tier web applicationsN tier web applications
N tier web applications
 
What’s new in x case 8
What’s new in x case 8What’s new in x case 8
What’s new in x case 8
 
Web 101
Web 101Web 101
Web 101
 
VFP & Ajax
VFP & AjaxVFP & Ajax
VFP & Ajax
 
Html for desktop applications
Html for desktop applicationsHtml for desktop applications
Html for desktop applications
 
Html and visual fox pro
Html and visual fox proHtml and visual fox pro
Html and visual fox pro
 
Error handling in visual fox pro 9
Error handling in visual fox pro 9Error handling in visual fox pro 9
Error handling in visual fox pro 9
 
Docking from a z in visual fox pro 9
Docking from a z in visual fox pro 9Docking from a z in visual fox pro 9
Docking from a z in visual fox pro 9
 
Client server
Client serverClient server
Client server
 
Introduction to afp
Introduction to afpIntroduction to afp
Introduction to afp
 
Where do you want to go today 2007
Where do you want to go today   2007Where do you want to go today   2007
Where do you want to go today 2007
 
Where do you want to go today
Where do you want to go todayWhere do you want to go today
Where do you want to go today
 

Recently uploaded

Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAndikSusilo4
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 

Recently uploaded (20)

Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & Application
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping Elbows
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 

JavaScript for FoxPro Developers: An Introduction to JavaScript Syntax and Features for Visual FoxPro Developers

  • 1. JavaScript for FoxPro Developers Mike Feltman F1 Technologies
  • 2. Who Am I? • President F1 Technologies since 1990 • Co-author Visual FoxExpress • Consultant
  • 3. Agenda • Why JavaScript? • VFP vs. JavaScript • JS Basics • JS Syntax & VFP Concordance • JS OOP • AJAX w/ VFP
  • 4. Why JavaScript? • Web 2.0 • Great way to take VFP Skills to the Web • In demand • Cross-Platform • Relatively easy for VFP Developers to pick up
  • 5. VFP vs. JavaScript: Runtime Environment VFP JavaScript – Operating System: – Operating System: • Windows • Windows, MAC, Linux, Version: Unix, etc. • VFP Compiler Version Version: • Browser Controlled: IE, Firefox, Opera, Safari, etc. • 1.5 current “standard”
  • 6. VFP vs. JavaScript: Development Environment VFP JavaScript – Designers: Editor, Form – Designers: n/a, Requires 3rd Class Designer, Report Party tools. No definitive Write, Class Browser, etc. IDE built-in. – Debugger: virtually nothing – Debugger: Integrated native. Varies by browser, debugger, with Trace, Firebug for Firefox and Watch, Locals, Output, Call Debugbar for IE. Stack – JavaScript Console various – Command Window other Command Window like utilities.
  • 7. VFP vs. JavaScript: Capabilities VFP JavaScript – Access to File System – No File System – Database Engine Access – Network access – Can’t read or write to limited only by network files on server security – Can’t read or write to files on client – No network access – Cannot access pages on another domain
  • 8. VFP vs. JavaScript: Language Features VFP JavaScript – Dynamically Typed – Dynamically Typed – Case Insensitive – Case Sensitive – “Second Class” – First Class Functions Functions – Nested Functions – No Nested Functions – Interpreted – Compiled or – OOP: Prototype based Interpreted – “0 based” – OOP: Class Based – “1 based”
  • 9. Syntax VFP JavaScript – Line Terminator: – Line Terminator: semi- carriage return colon – Line Continuation: – Line Continuation: n/a semi-colon
  • 10. Math Operators Function VFP JavaScript Addition + + Subtraction - - Multiplication * * Division / / Modulus MOD() % Unary addition x=x+1 x++ Unary x=x-1 x-- subtraction
  • 11. Assignment Operators Function VFP JavaScript Equality = = Addition n/a += Subtraction n/a -= Multiplication n/a *= Division n/a /= Modulus n/a %=
  • 12. Comparison Operators Function VFP JavaScript Equality =,== == Greater than >, >= >, >= Less Than <, <= <, <= Identical & of n/a === Same Type Not Identical !=,!==,<> !== Inline IF IIF() (condition)?true value: false value
  • 13. Logical Operators Function VFP JavaScript And AND && Or OR || Not NOT, ! !
  • 14. Constructs: If VFP: JavaScript: IF if (logical expression) statement(s) {statement(s)} ELSE else if (logical statement(s) expression) ENDIF {statements} else {statement(s)}
  • 15. Constructs: While VFP JavaScript DO WHILE expression while (expression) statements { ENDDO statements } EXIT break LOOP continue
  • 16. Constructs: For VFP JavaScript FOR var = n to n STEP n for statements (var=startvalue;var<= ENDFOR endvalue;var=var+inc rement) { statements }
  • 19. Forms