53
Concepts

Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

  • Upload
    others

  • View
    7

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Concepts

Dessin.book Page 1 Jeudi, 25. août 2005 11:55 11

Page 2: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

WinDev - ConceptsVersion 9 US - (1) 09-05

Visit the download center at www.windev.com to check for updates.

This documentation is not contractually binding. Modifications may have been made tothe software the since this guide was published. Please consult the online help.

All product names or other trademarks mentioned in this publication are registered trademarks of their respective owners. © PC SOFT 2005: This publication may not be reproduced in part or in whole in any form without the express permission of PC SOFT.

Dessin.book Page 2 Jeudi, 25. août 2005 11:55 11

Page 3: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Win

Dev:

Main

Con

cep

ts

3

In what order should the guides be read?

WinDev 9 is a powerful Windows application development tool. It provides all the toolsneeded to design and create applications.

To learn quickly and efficiently how to use WinDev 9, we advise you to work in thefollowing order:

1 Read the "Concepts". This guide presents the main concepts needed to create a high-powered WinDevapplication.

2 "Tutorial" (book + exercises)The Tutorial provides a first "hands-on" approach to WinDev, to familiarize yourselfwith the main WinDev editors.

3 Test the examplesTest the examples delivered with WinDev in the fields you are interested in(commercial management, scheduling, and so on.)

The online help lets you find the syntax of a W-Language function quickly, obtain help onthe interface, and so on.

Note: If there is a difference between the guide and the online help, follow the instructionsin the online help.

We hope you enjoy getting started with WINDEV.

Dessin.book Page 3 Jeudi, 25. août 2005 11:55 11

Page 4: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Win

Dev:

Main

Con

cep

ts4

Dessin.book Page 4 Jeudi, 25. août 2005 11:55 11

Page 5: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Win

Dev:

Main

Con

cep

ts

5

Table of contentsPart 1: Developing an applicationDevelopment environment 9Project and analysis 10Custom folders: Organizing your project 11MDI / non-MDI application 12Choosing a type of control according to the information to be displayed 13RAD 14Component 15Multi-product components 16Report 17UMC: User Macro-Code 18Multilanguage application 19Creating a Java application with WinDev 20

Part 2: DatabaseTypes of files that can be accessed 23Linking a control to its heading 24Classic Hyper File 25Client/Server Hyper File 26Queries 27Embedded queries 28

Part 3: CommunicationEmail management 31File transfer by FTP 32Socket management 34Stream management (videoconferencing) 36Telephony 37Web services 38

Part 4: Test and setupTests available 41Debugger 42Optimizing an application 43Application setup modes 44

Part 5: AppendixExamples supplied with WinDev 51

Dessin.book Page 5 Jeudi, 25. août 2005 11:55 11

Page 6: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Win

Dev:

Main

Con

cep

ts6

Dessin.book Page 6 Jeudi, 25. août 2005 11:55 11

Page 7: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part 1 Developing an application

Dessin.book Page 7 Jeudi, 25. août 2005 11:55 11

Page 8: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Dessin.book Page 8 Jeudi, 25. août 2005 11:55 11

Page 9: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

1:

Develo

pin

g a

n a

pp

licati

on

9

Development environment

WinDev is a development environment for developing Windows applications on PC.

Windows PC

Client Computer

Using the WinDevapplication

SETUP

GORunning theapplicationtest

Creating the executable

Installing WinDev

Developing theapplication

Creating the setupprogram

Dessin.book Page 9 Jeudi, 25. août 2005 11:55 11

Page 10: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

1:

Develo

pin

g a

n a

pp

licati

on

10

Project and analysis

A WinDev project is a set of windows, controls, classes, components, etc. for creating aWindows application.

A WinDev analysis contains the data file descriptions.

A project is usually associated with an analysis. An analysis can be associated with one or more projects.

To create the application "ihavelovelyeyes", create the project "ihavelovelyeyes".

Project 1

Project N

Project 2

Analysis

ClassesClasses

Classes

Stylesheet Style

sheet

Stylesheet

Pages andcontrols Pages and

controls

Pages andcontrols

Dessin.book Page 10 Jeudi, 25. août 2005 11:55 11

Page 11: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

1:

Develo

pin

g a

n a

pp

licati

on

11

Custom folders: Organizing your projectThe WinDev project editor enables you to map the entire project. With large projects, browsing the representation produced by the project editor can bedelicate. The creation of "custom folders" makes browsing easier.

A "custom folder" contains the elements you put in it, part of the application, for example:customer management, supplier management, ...Elements can be common to several "custom folders". This makes it easier to work on part of the application.

Content of the developer custom folder

Content of the order custom folder

Windows, reports, queries relating to orders

Windows, reports, queries relating to developers

Dessin.book Page 11 Jeudi, 25. août 2005 11:55 11

Page 12: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

1:

Develo

pin

g a

n a

pp

licati

on

12

MDI / non-MDI application

Two types of applications can be created in Windows: - MDI applications- non-MDI applications

MDI applicationsAll the windows of an MDI application are displayed in the same main window. Thewindows of MDI applications can therefore be of two types:

Non-MDI applicationsThe windows of a non-MDI application are displayed one after another in a stack. You canhandle only the last window displayed. The previous windows are not accessible.

MDI parent window: All the other windowsof the application are displayed in it. Thisis where you handle the main name of theapplication.

MDI child window: Window of theapplication displayed in the parentwindow. These is where you can enterinformation.

Dessin.book Page 12 Jeudi, 25. août 2005 11:55 11

Page 13: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

1:

Develo

pin

g a

n a

pp

licati

on

13

Choosing a type of control according to the information to displayWinDev offers a number of different controls:

If you want ... The type of control touse is:

To display text, a title, etc. Static

To select a value from a list (country, city, etc.) Radio button, Combo box, List box

To select several values from a list (message recipients,etc.)

Check box, List box

To display a graphic image (photo, statistics chart, linechart, etc.)

Image

Display an animation (animated Gif) Image

Display the content of a file in a table (customer list, orderdetails, etc.)

Browsing table, memory table

Display a regularly refreshed image Web camera

Enter information Edit control

Display ranked information (directory content, etc.) TreeView

Dessin.book Page 13 Jeudi, 25. août 2005 11:55 11

Page 14: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

1:

Develo

pin

g a

n a

pp

licati

on

14

RADRAD (Rapid Application Development) can be used to create windows: - from the analysis linked to the project- from standard RAD patterns- from custom RAD patterns- from templates.

Analysis TemplateRAD pattern

RADFull application RAD

Window RAD

Example of window generated by RAD

Dessin.book Page 14 Jeudi, 25. août 2005 11:55 11

Page 15: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

1:

Develo

pin

g a

n a

pp

licati

on

15

ComponentA component is a set of WinDev elements: windows, reports, analysis, etc. that performsa specific feature, for example:

- Send faxes- Send emails

...A WinDev component can be distributed to other WinDev developers (free of charge ornot). They can then simply include the features offered by the component in theirapplication. The component will be included in the application and distributed with it.

WinDev Project

WinDev project

.WDK file

Componentdevelopment

Import the component into WinDev projects

Use the component

Component generation

WinDev project

Use the component

Dessin.book Page 15 Jeudi, 25. août 2005 11:55 11

Page 16: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

1:

Develo

pin

g a

n a

pp

licati

on

16

Multi-product componentsWith WinDev, WebDev and WinDev Mobile, you can create multi-product components.These can contain windows, pages, etc. and be used in WinDev, WebDev or WinDevMobile projects.

This is how they work:

The projects linked to the WinDev project are defined in the "Multi-product" tab of the"Project .. Project description" option.

Component creation- Selection of elements- Choice of target products(WinDev, WebDev, etc.)

WebDevproject

Project linked to the master WinDev project

WinDev Mobile project

Project linked tothe master WinDevproject

WinDevprojectMaster project

HTML pages to include into the component

Window to include into the component

WDK and WDI filesUsable in the projects of thetarget products

Dessin.book Page 16 Jeudi, 25. août 2005 11:55 11

Page 17: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

1:

Develo

pin

g a

n a

pp

licati

on

17

ReportA report gives a custom view of information: data entered in the database, data in a textfile, data from a table control, etc.

A report can be displayed on screen, saved to an HTML file, printed directly, etc.

A report can be used to summarize and synthesize data. You can:- group data. - sort data on a criterion. - perform calculations, produce averages, statistics or even charts.

The diagram below shows a simplified definition of a report:- data to print comes from a data source (file described in an analysis, Hyper File view,

query, memory zone or text file). - the report groups, sorts and formats data.- the report can be displayed on screen, saved in an HTM or RTF file, or printed.

Txt

Rep

ort

sour

ces

PDF

Txt

XLS

Table

Memoryzone

Query

Text file

Data

HTML, XML files

XLS, PDF files

Text files

Report

Printout on printer P

rint m

odes

Dessin.book Page 17 Jeudi, 25. août 2005 11:55 11

Page 18: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

1:

Develo

pin

g a

n a

pp

licati

on

18

UMC: User Macro-Code

UMC mode allows the end-user to enter W-Language code and include it into an existingapplication.

Let’s look at the following case: An edit window of a customer form requires the presence of an email address but doesnot check its format. You want to check at least the presence of the "@" character in theaddress.

To activate this feature, when creating the executable simply indicate that it accepts UMCmanagement.

An icon at the top of the window lets youcustomize the processes.

The UMC configuration window appears. Youcan add a new action for this window. In thiscase, you add email address checking.

You enter the W-Language code. To access theW-Language help, press F1.

Dessin.book Page 18 Jeudi, 25. août 2005 11:55 11

Page 19: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

1:

Develo

pin

g a

n a

pp

licati

on

19

Multilingual applicationA multilingual application is an application that can be distributed in several languages.WinDev takes into account the different languages of the application at all stages ofapplication development.

The main steps in developing a multilingual application are:

Choice of languages- Project- Analysis

Translation- Window- Code- Report

Direct translation in the interface

Extraction of messages for translation (WDMSG, WDINT)

Programming

- Choice of language for the application (Nation function)- Choice of charset, if necessary (ChangeCharset function)- Choice of keyboard language (ChangeKeyboard function)

Data files- Choice of charset, if necessary (ChangeCharset function)- Use of charset during file creation (HCreation, HCreationIfNotFound)- Use of charset during reindexing (HIndex)

ExecutableSelection of languages to include in the library

Setup programSelection of languages to include in the library

Translation of setupprogram, if necessary

Dessin.book Page 19 Jeudi, 25. août 2005 11:55 11

Page 20: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

1:

Develo

pin

g a

n a

pp

licati

on

20

Creating a Java application with WinDevThe steps in creating a Java application with WinDev are:

Java

Java

Analysis

JAVA RAD

Windows

W-LanguageCompatible functions only

- Creation of the Java files - Automatic compile (Sun SDK, version 1.4.2 or later if necessary)

Redistributable Java application(.JAR file)

Creation of Java archive

Sets of procedures

Dessin.book Page 20 Jeudi, 25. août 2005 11:55 11

Page 21: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part 2 Database

Dessin.book Page 21 Jeudi, 25. août 2005 11:55 11

Page 22: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Dessin.book Page 22 Jeudi, 25. août 2005 11:55 11

Page 23: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

2:

Data

base

23

Types of files that can be accessedWinDev, WebDev and WinDev Mobile offer simple access to the most common databases.

UDC: Universal Data Connector (HReadSeek, HExecuteQuery, File, Item, Automatic filelink, SQLExec, ...)

Progress

AS/400

XML

MySQL

Sybase

Informix

DB2SQL Server

Oracle

Classic

Mobile

ODBCOLE DB

Windows

Linux

Client / Server

NativeHyper File

UDC

Native access

Dessin.book Page 23 Jeudi, 25. août 2005 11:55 11

Page 24: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

2:

Data

base

24

Linking a control to its itemTo display information from a database in a window, you have to link the window controlsto the database items. It is very easy to display and retrieve information: - You define the link between a control and an item in the Window Editor when you

describe the control ("File" tab). - The ScreenToFile function is used to update the record with the data displayed on

screen. - The FileToScreen function is used to update the data displayed on screen with the

information saved in the file.

FileToScreen

ScreenToFile

Database

Dessin.book Page 24 Jeudi, 25. août 2005 11:55 11

Page 25: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

2:

Data

base

25

Hyper File ClassicA WinDev Hyper File application can operate in multiuser or client/server mode.

The characteristics of multiuser mode are: - A multiuser Hyper File application is run on different user workstations. - The data files are located in a directory accessible to user workstations. Each user

workstation physically accesses the data files. - The processes (query, read/add operations in file, ...) are performed on each user

workstation.

User 3

WinDevApplication

MultiuserHyper File databases

(shared directory)

User n

WinDevApplication

User 1

WinDevApplication

User 2

WinDevApplication

Dessin.book Page 25 Jeudi, 25. août 2005 11:55 11

Page 26: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

2:

Data

base

26

Hyper File Client/ServerA WinDev Hyper File application can operate in multiuser or in client/server mode.

The characteristics of client/server mode are: - A client/server Hyper File application is run on different user workstations (called client

computers). - The data files are located on a server. Only the server physically accesses the data

files. - All processes (query, read/add operations in file, etc.) are performed on the server.

Client Computer 1

WinDevApplication

Client Computer 2

WinDevApplication

Client Computer n

WinDevApplication

Windows or LinuxHyper File server

Manta Server

Client/ServerHyper FileDatabases

Connection type: Network,USB, Wi-Fi,Internet...

TCP/IP Protocol

Dessin.book Page 26 Jeudi, 25. août 2005 11:55 11

Page 27: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

2:

Data

base

27

QueriesQueries are used to interrogate a database to view, insert, modify or delete data. Thestructure of the query defines the data used.A query can interrogate one or more files.Queries can be created very simply with the Query Editor, without programming.

The query result is used in the sameway as a file

Data from one or more files(Hyper File, Oracle, etc.)

Window and controls of a window ("Content" tab)

Reports

Programming (used in W-Language functions)

Queries

Query

Dessin.book Page 27 Jeudi, 25. août 2005 11:55 11

Page 28: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

2:

Data

base

28

Embedded queriesWindow controls can be linked to a data file, an existing query, etc. They can also be linkedto a query created when the control is designed.

In this case, the query is embedded in the window and is in the appropriate WDW file. Ifthe WDW file is transmitted, the embedded queries used by the window are also supplied.

Embedded query: MyWindow_2$Query

Embedded query: MyWindow_1$Query

Dessin.book Page 28 Jeudi, 25. août 2005 11:55 11

Page 29: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part 3 Communication

Dessin.book Page 29 Jeudi, 25. août 2005 11:55 11

Page 30: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Dessin.book Page 30 Jeudi, 25. août 2005 11:55 11

Page 31: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

3:

Co

mm

un

icati

on

31

Email managementWinDev uses two methods for managing emails:- the POP3 / SMTP protocols (most common) which are email management protocols

supported by all Internet Service Providers. They enable you to dialog directly with theserver your ISP makes available.

- Simple Mail API (also called SMAPI or Simple MAPI): this email management methodis used by most Microsoft applications, especially Microsoft Exchange.

Email Server(Host)

POP3 Service SMTP Service

Local computer (User)

POP3 ProtocolReceiving emails

SMTP ProtocolSending emails

RemoteAccess

WinDevApplication

Emails Server(Host)

User Profile

Local Computer (User)

Simple MAPIWinDev

Application POP3 Service SMTP Service

Dessin.book Page 31 Jeudi, 25. août 2005 11:55 11

Page 32: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

3:

Co

mm

un

icati

on

32

File transfer by FTPThe FTP (File Transfer Protocol) is a protocol for transferring files between sites via TCP/IP or the internet.

How it worksTo use files from a WinDev application on an FTP server:

1. Connect to an FTP server (FTPConnect function).

2. Send and retrieve files (depending on the connection mode used). In case of passiveconnection, the WinDev application must request authorization from the FTP serverwhenever it needs to use files on the server. You can also: - obtain the characteristics of files on an FTP server: attributes, size, etc.- handle files on an FTP server: create, delete, etc.- list the files in a directory on an FTP server by executing a procedure that runs a

process for each file found.

3. Close the connection to the server (FTPDisconnect function).

Dessin.book Page 32 Jeudi, 25. août 2005 11:55 11

Page 33: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

3:

Co

mm

un

icati

on

33

FTP Server

FTP Server

FTP Server

1 Connection

FTP Account

Anonymous

FTP ServerUser Workstation

ConnectionWinDev application

3 Disconnection

User Workstation

WinDev application

Disconnection

2 Communication

User WorkstationAuthorization request

WinDev application

Validation

Action

Passive Connection (necessary with a FireWall on the FTP Server)A

User Workstation

WinDev application

Action

Active ConnectionB

1

2

3

Dessin.book Page 33 Jeudi, 25. août 2005 11:55 11

Page 34: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

3:

Co

mm

un

icati

on

34

Socket managementWinDev provides advanced socket management functions. A socket is a communication resource used by applications to communicate betweencomputers without worrying about the type of network. It can be used, for example, to communicate between workstations connected by theInternet.

The optionsWinDev applications can handle sockets in different modes:

- WinDev Client application: the application connects to any type of server andexchanges data via a socket.

- WinDev "Simplified Server" application: the WinDev application is a server thatexchanges information via a socket with a single client workstation (WinDev socketadvisable but not mandatory on the client workstation)

- WinDev "Standard Server" application: the WinDev application is a server thatexchanges information via sockets with several client workstations of any type.

Client applicationA client application of a socket server connects to any type of server to exchangeinformation via a socket.

Example: A WinDev client application can connect to a standard Internet news server.

Step 1: Connection to the serverTo connect to a server socket, use SocketConnect. This function is used to requestconnection to the server. The socket is identified by its port and its address.

Step 2: Data exchangeOnce both workstations have connected their socket, a communication flow is establishedbetween them and they can read and write character strings via the socket. To read and write via the server socket, the WinDev client application must use theSocketRead and SocketWrite functions.

Step 3: Stopping the communicationTo stop the communication, close the socket on the client workstation with theSocketClose function. The steps can be represented as follows:

Dessin.book Page 34 Jeudi, 25. août 2005 11:55 11

Page 35: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

3:

Co

mm

un

icati

on

35

Client workstation

Client workstation

Server

Server

SocketRead

SocketWrite

Connection

Client workstation

SocketConnect

Read, Write

Server

SocketClose

Disconnection

Dessin.book Page 35 Jeudi, 25. août 2005 11:55 11

Page 36: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

3:

Co

mm

un

icati

on

36

Stream management (videoconferencing)To handle communication streams, WinDev provides:- the Conference control- W-Language STREAM functions.

This enables two users to communicate with one another. The image and voice of eachuser are transmitted in real time on both connected workstations.

Examples of applications using streams:- videoconferencing,- direct retransmission of a press conference,- and so on.

Please note:

- The current workstation and the connected workstation(s) must be equipped with aweb camera and/or microphone. If one of the workstations does not have a webcamera or a microphone, the corresponding image or voice will not be transmitted.

- You can only view the video sequences currently transmitted by the web camerasinstalled on the connected workstations. You cannot view video files.

- You can only listen to the sounds currently transmitted by the microphones installedon the connected workstations. You cannot to listen to sound files.

WinDev application with one or more

conferencing controls

Microphone

Web camera

Sound and video transmission

Client Workstation

Client Workstation

Dessin.book Page 36 Jeudi, 25. août 2005 11:55 11

Page 37: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

3:

Co

mm

un

icati

on

37

TelephonyThe W-Language telephony functions in WinDev make incoming and outgoing phone callssimple to handle. They include functions to handle a voice mailbox, an answeringmachine, etc. directly in a WinDev application.

Configuration required: To use the telephony features, you need: - a modem.

To save and play back recordings, the modem must support vocals. To identify the caller, the modem must support Caller ID.

- the Tapi 2.0 protocol. This technology can be used on all systems, but you need: - at least Service Pack 4 installed if the OS is Windows NT4 - to update your system if it is Windows 95 (update available from ftp://ftp.microsoft.com/developr/tapi/tapi2195.zip). Address valid at the time of publication.

Client workstationwith modem

WinDev application

- Call detection- Identification of the calling number

Automatic dialing

Dessin.book Page 37 Jeudi, 25. août 2005 11:55 11

Page 38: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

3:

Co

mm

un

icati

on

38

Web servicesWinDev has two ways to manage Web Services: - Use of existing Web Services- Generation of a Web Service

Using a WEB ServiceYour WinDev application can use an existing Web Service. You just need to know itsaddress and import its description into the application.

Generating a WEB ServiceA WinDev application can be a Web Service itself. In this case, the WinDev applicationrepresents a set of procedures. This Web service can be used by any type of application.You just need to install it on a server.

WEB server

Web Service

Importing the service description

Development workstation

WinDev executable

Using the Web Service

WEB server

Web Service

Development workstation

Generating the Web Service and installing iton server

- WinDev Framework- DLLs specific to the WEB server used

Standard application Using of the Web

Service

Dessin.book Page 38 Jeudi, 25. août 2005 11:55 11

Page 39: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part 4 Test and setup

Dessin.book Page 39 Jeudi, 25. août 2005 11:55 11

Page 40: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Dessin.book Page 40 Jeudi, 25. août 2005 11:55 11

Page 41: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

4:

Tests

an

d s

etu

p

41

Available testsWinDev has several ways to test an application. The table below presents the differentmodes.

Type of test Description

Test of entire project Simulates the running of the application by theexecutable. Allows you to test the entire application,even if its development is not complete. As soon as a problem appears when running theproject, you can start the debugger to identify andsolve it.

Test of current element To test the operation of the element as soon as itsdevelopment is complete. The debugger can be run immediately when aproblem occurs in reports or windows.

Step-by-step project test To run the debugger when the application starts.Enables you to monitor the application flow in detail.

Regression test To test the regression of an element betweendifferent versions of an application. Just select (or create) a test scenario to run.

Dessin.book Page 41 Jeudi, 25. août 2005 11:55 11

Page 42: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

4:

Test

an

d s

etu

p42

DebuggerA debugger is supplied with the standard WinDev package to allow you to debug yourcode. The debugger lets you run your applications step by step and view executed W-Languagecode, variable contents, and so on.

To run the debugger, use:

- either a breakpoint set directly in the code editor: the debugger will be automaticallyrun when the line with the breakpoint in front of it is executed. To set a breakpoint, click beside the code line: a red bullet appears.

- or the W-Language server keyword Stop in your W-Language code: the debugger willbe automatically run when the code line is executed.

- or the "Project .. Test Mode .. Trace Project" option: the debugger will be run at thesame time as the test of the dynamic site.

Dessin.book Page 42 Jeudi, 25. août 2005 11:55 11

Page 43: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

4:

Tests

an

d s

etu

p

43

Optimizing an applicationWinDev has two ways to optimize applications: - Aided application development: code or interface improvements are suggested during

the development of the application.- The profiler: lets you rapidly view the most time-consuming processes. You then simply

optimize the required process.

Application development

Application test

Optimize your queries, improve anchoring in your windows, etc. Such suggestions are made regularly as you develop your applications.

Profiler output on the application during a test, view of the longest processes to optimize code immediately.

To run the profiler, use the "Project .. Profiler" option.

Dessin.book Page 43 Jeudi, 25. août 2005 11:55 11

Page 44: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

4:

Test

an

d s

etu

p44

Application setup modes

Traditional setupThis involves creating a setup program that will be installed on each client workstation bya setup medium.

Development workstation

Client workstation

Creating the executable

Creating the setup program Setup medium

(CD-ROM, USB key, etc.)

Setup

Using the application

Client workstation N

Setup

Using the application

Setup medium (CD-ROM,USB key, etc.)

Dessin.book Page 44 Jeudi, 25. août 2005 11:55 11

Page 45: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

4:

Tests

an

d s

etu

p

45

Multiuser setupThis involves creating a setup program that will be installed on a server workstation. Allclient workstations wishing to install the application will run the setup program via thenetwork.

If an update is available on the application server, you will be asked whether you want toupdate the application on your computer.

Development workstation

User workstation

Creating the executable

Creating the setup program

Using the application

User Workstation N

Using the application

Application server

Setup medium

Setup

Setup via network

Setup via network

Dessin.book Page 45 Jeudi, 25. août 2005 11:55 11

Page 46: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

4:

Test

an

d s

etu

p46

Install IP

This involves creating a setup program that will be installed on a Web Server. All client workstations wishing to install the application will run the setup program via anIP address, HTML page, etc.

If an update is available on the WEB server, you will be asked whether you want to updatethe application on your computer.

Development workstation

User workstation

Creating the executable

Creating the setup program

Using the application

User workstation N

Using the application

WEB server

Setup medium

Setup

Setup via internet

Setup via internet

Dessin.book Page 46 Jeudi, 25. août 2005 11:55 11

Page 47: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

4:

Tests

an

d s

etu

p

47

FrameworkThe WinDev Framework is the set of libraries (.DLL files) required for a WinDev applicationto operate. When you create the executable, you can choose to use either the Framework specific toyour application or the common Framework.

Directory of common WinDev Framework

Setup directory of an application using the common WinDev Framework. Only theexecutable is installed in this directory (and, if necessary, the files for uninstalling theapplication).

Setup directory of an application using the custom Framework. The PC SOFT DLLs areinstalled in the application directory.

Dessin.book Page 47 Jeudi, 25. août 2005 11:55 11

Page 48: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

4:

Test

an

d s

etu

p48

Dessin.book Page 48 Jeudi, 25. août 2005 11:55 11

Page 49: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part 5 Appendix

Dessin.book Page 49 Jeudi, 25. août 2005 11:55 11

Page 50: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Dessin.book Page 50 Jeudi, 25. août 2005 11:55 11

Page 51: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

5:

Ap

pen

dix

51

Examples supplied with WinDevThe examples supplied with WinDev describe the different features of WinDev in didactic form.Their source code is commented in detailsThey are located in the "Examples" subdirectory of the WinDev setup directory and can be openeddirectly from the Kouglof ("Wizard Catalog" tab, "Examples" button).

Different types of examples are supplied with WinDev:•Complete examples: these correspond to complete applications and can be used without

adaptation. •Teaching examples: these illustrate a specific feature.

Below are the features of a few examples supplied with WinDev.

Complete examples

Teaching examples

WD Live Messenging Presents the functions of socket management inWinDev.

WD POP3 To send and receive emails (with or withoutattachments, etc.).

WD Search on Internet To run internet search engines (Yahoo, Alta Vista, Voilà,Lycos, Excite, Nomade, Google, Euroseek, etc.).The search result is displayed using an ActiveX.

WD File Synchronization To synchronize two file directories. After synchronization, the destination directory isidentical to the source directory. The comparison isbased on the presence and date of the files.

WD FTP File Transfer To transfer files:- from an FTP server to the local workstation,- from the local workstation an FTP server.

WD Alarm Displays an alarm message in the title bar of the activewindow (regardless of the application). The messagecan be accompanied by an audible alarm.

WD Dynamic Compilation Presents:- Dynamic compiling of W-Language code- Running dynamically compiled code- Processing of run-time errors

Dessin.book Page 51 Jeudi, 25. août 2005 11:55 11

Page 52: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

5:

Ap

pen

dix

52

WD Input Check Checks the data entered by the user (name, company,zip code, city, email address, etc.) in a form window.

WD Draw Shows parts of a scanned document or annotatesimages, using the W-Language draw functions.

WD Drag and Drop Windows Offers an image catalog. Images can be added by dragand drop from Windows Explorer.

WD Advanced Reports Presents different types of reports.Illustrates:- internal reports - the chart control - printing to a RTF, HTML or PDF file

WD HTML Export Manages external files. Also presents the use of HTMLfiles.

WD Text Files Manages external files (creation, deletion andmodification of file contents).

WD HTML Page Import Saves an HTML page from a website. The page isanalyzed and all its dependencies (images, applets,etc.) are also imported.Remark: This is not an offline browser. The pages canonly be downloaded one at a time.The principle used in the example can also be used toretrieve information from pages whose format isknown (for example, daily retrieval of stock exchangequotations).

WD Number in Words To convert a numeric value into letters.The conversion is then displayed in a "Check-letter"report.

WD Excel Control To control Excel via OLE Automation. All Excelfunctions are available.

WD Search on CompositeKeys

Presents the use of filters and composite keys tooptimize search times for Hyper File data files.

WD Grouping Task List To group together all the tasks of several projects.

WD Queries To perform calculations, pass parameters or print theresult of a SQL query in a Hyper File data file.

Dessin.book Page 52 Jeudi, 25. août 2005 11:55 11

Page 53: Concepts - PC SOFT WINDEVpcsoft-windev-webdev.com/usconcepts/windev/Concepts.pdf · 2020-02-04 · WinDev 9 is a powerful Windows application development tool. It provides all the

Part

5:

Ap

pen

dix

53

Further examples will be available from our website (www.windev.com).

WD Tables and Combo Boxes To select a product in a combo box and display theinformation about it in a table. The description of each product is in RTF format and isillustrated with an image.

WD TreeView Presents the use and management of TreeViewcontrols.

WD Using Aliases To handle the same physical data file through severalaliases.

WD Using Sockets Presents the use of sockets in client/server mode.Each socket is handled via a thread.

WD Clickable Area Manages click areas on non-rectangular shapes. When the map is clicked, the selected area isdisplayed at the bottom of the screen.

Dessin.book Page 53 Jeudi, 25. août 2005 11:55 11