sexta-feira, 4 de setembro de 2020

DICAS 3067 -WEBDEV TUTORIAL 1-Licao 1.1-14-09-2020 11hrs-DESCUBRA WEBDEV




https://youtu.be/154bTRzhfNo


Bom Dia/Boa Tarde/Boa Noite


Esse Ao Vivo vai estrear as 11:00 do dia 14/09/2020 

DICAS 3067 -WEBDEV TUTORIAL 1-Licao 1.1-14-09-2020 11hrs-DESCUBRA WEBDEV

Lesson 1.1. Discover WEBDEV


ASSUNTOS

VISAO GERAL
INICIANDO WEBDEV
AMBIENTE DE DESENVOLVIMENTO
O EDITOR
CORES DO AMBIENTE 
WLANGUAGE

PlayList WebDev tutorial Amarildo Webdev


DICAS 3067 -WEBDEV TUTORIAL 1-Licao 1.1-14-09-2020 11hrs-DESCUBRA WEBDEV
DICAS 3068 -WEBDEV TUTORIAL 1-Licao 1.2-14-09-2020 15hrs-Web development and WEBDEV - PARTE A







Playlist Windev Tutorial Amarildo Windev
Playlist windev Franca PcSoft
Amarildo
Windev
WxSolucoes
Matos Informatica
Repositorio Windev
Site forum Google 
Video sobre 3 Mil Videos Windev 
PlayList Pedrosao
Video sobre Alfaserver servidor 











Lesson 1.1. Discover WEBDEV
This lesson will teach you the following concepts
  • Starting WEBDEV.
Lesson duration

Estimated time: 5 mn
Table of contentsNext Lesson
Overview
WEBDEV is a complete DevOps Integrated Development Environment aimed at developing sophisticated Internet and Intranet sites in diverse fields: e-commerce, multimedia, ...
The developed sites can give access to information stored in the databases.
WEBDEV allows you to create:
  • static Internet/Intranet sites. These sites manage data that does not vary (company showroom site, site available on a DVD-ROM, etc.).
  • dynamic Internet/Intranet sites, that manage data. The WEBDEV sites access all databases, relational or not, available on the market.
Throughout this tutorial, you will learn how to create your sites (with or without a database) and how to enrich them using the many features offered by WEBDEV.
Starting WEBDEV
  • Start WEBDEV 25 if necessary.
  • When WEBDEV 25 is launched for the first time, a welcome wizard will start:
    • If you have worked with an earlier WEBDEV version, this wizard allows you to retrieve the existing configurations.
    • If you are a new user, this wizard allows you to configure your environment. This allows you to choose the screen configuration used and to configure the Control Centers.
  • If you have already launched WEBDEV 25, identify yourself if necessary. The development environment starts. The WEBDEV home page is displayed.
    Home page
    This home page allows you to:
    • display the news,
    • create a project,
    • open an existing project,
    • open an example,
    • open one of the projects from the tutorial.
  • Let's take a look at the development environment of WEBDEV. To do so, from the WEBDEV home page:
    • Click "Tutorial".
    • Double-click "Full WEBDEV Site (Answer)".
      Examples of the tutorial
    • The corresponding project is opened in the editor. The project dashboard is displayed. The project dashboard allows you to check the progress of a project via several elements (called widgets).
      Project dashboard
Development environment

The editor

The development environment of WEBDEV includes a specific interface and several editors allowing you to create the different elements of your applications.
For example, the page editor is used to create pages, the report editor is used to create reports, ...
  • To discover WEBDEV, we will open the page used to list the products:
    1. Press Ctrl + E.
    2. In the window that is displayed, type the name of the page to open: PAGE_List_of_products.
    3. Validate. The page is displayed in the editor.
All editors use the same environment:
Environment of editors
  1. Menu of editors, displayed in ribbon format (we'll see how to use it in the next paragraph).
  2. Current editor (here, the page editor). This space allows you to see the element currently created or modified in WYSIWYG (What You See Is What You Get).
  3. Panes. The WEBDEV interface includes several horizontal and vertical panes allowing you to quickly access different types of information.
    Some examples:
    • The "Project explorer" pane (displayed on the right) is used to list all the project elements by category.
    • The "Find - Replace" pane (displayed at the bottom) is used to quickly perform searches in your project.
    These panes can be hidden by pressing Ctrl + W if necessary.
  4. Open documents bar. This bar is used to quickly see all open elements. A simple click on the button corresponding to the element displays it in its own editor.

The menu bar (ribbon) in details

The menu bar of WEBDEV is presented in ribbon format. This ribbon includes panes in which the different options of editors are grouped.
We are going to take a closer look at the main ribbon elements, as well as how we will use it in this tutorial.
Ribbon of editors
The different ribbon elements
The ribbon includes 3 areas:
  • the button area, on the left (1).
  • the pane area, at the top (2).
  • the option area (3).
Let's take a closer look at these areas.
The button area (1)
Button area
The button area groups the quick access buttons. These buttons are used to perform the most usual operations, common to all editors: save, open, create, ...
The product logo is used to display the "About" window, the custom menus and the drop-down menus found in the former interface of editors.
The arrow at the top right of the button area allows you to find the toolbars and drop-down menus of the old editor interface.
The pane area (2)
Pane area
The different ribbon panes are used to access the options of different editors for the current project. Several types of panes are available:
  • the current pane: The name of the pane appears in bold and is underlined by a blue line.
  • the popup panes, specific to the current element: The pane name is displayed in blue.
  • the available panes: The pane name is displayed in black.
The option area (3)
Option area
The options displayed in the ribbon differ according to the selected pane. Several types of options are available:
  • Options to check,
  • Buttons to click,
  • Button with arrows used to expand the options. There are two types of buttons with arrows:
    • the buttons with arrow used to expand a menu,
    • the buttons with arrows used to expand a menu (click on the arrow) or to perform a default action (click on the button icon).
The options are organized by group. Each group of options has a name and it can also include a group button Group button. This button is used to perform a specific action according to the current group: open the description of the current element, open the help, ...
In this tutorial, to identify a menu option, we will be talking about panes and groups. For example: "To display the help, go to the "Home" pane, "Online help" group and click "Help"."

The environment colors

The environment uses a light theme by default.
Several other themes are also available:
  • Light theme, grey ribbon. In this mode, the menu bar is not colored anymore: it is grayed.
  • Gray theme. In this mode, the environment and the interface windows are displayed on a light gray background.
  • Dark theme. In this mode, the environment and the interface windows are displayed on a black or dark gray background.
  • To modify the theme used by the environment:
    1. On the "Home" pane, in the "Environment" group, expand "Options" and select "General options of WEBDEV".
    2. In the "Editor" tab, in the "Themes" area, select the theme to use.
    3. Validate. The theme will be taken into account during the next WEBDEV start.
  • To improve the readability of this manual, the light theme will be used for the different images that illustrate the operations to perform.
  • To continue this lesson, we are going to close the current project:
    1. On the "Home" pane, in the "General" group, expand "Close" and select "Close project".
    2. Save the modified elements if necessary.
    3. The WEBDEV home page is displayed.
WLanguage
WLanguage is the programming language common to WINDEV, WEBDEV and WINDEV Mobile.
If you are not familiar with this language, we advise you to follow the lessons presenting the programming concepts. These lessons present the different types of variables, the main WLanguage statements, the procedures, ...




DICAS 3066 -WINDEV TUTORIAL 89 -Licao 7.9-12-09-2020 11hrs-The OOP





https://youtu.be/ou6IdHeF1e8


Bom Dia/Boa Tarde/Boa Noite

Esse Ao Vivo vai estrear as 11:00 do dia 12/09/2020 

DICAS 3066 -WINDEV TUTORIAL 89 -Licao 7.9-12-09-2020 11hrs-The OOP
Tutoriel WINDEV : Leçon 7.9. Programmation avancée - La POO


ASSUNTOS
..
OOP - CONCEITOS
CLASSES
OBJETOS
MEMBROS
METODOS 
HENRANCA 
CONTRUTOR E DESTRUTOR
EXEMPLO
DECLARANDO 
DIAGRAMA UML
DESPEDIDA DO TUTORIAL 


Video original da Franca
https://youtu.be/dezl--vdqbM


Playlist Windev Tutorial Amarildo
Playlist windev Franca PcSoft
Amarildo
Windev
WxSolucoes
Matos Informatica
Repositorio Windev
Site forum Google 
Video sobre 3 Mil Videos Windev 
PlayList Pedrosao
Video sobre Alfaserver servidor 

DICAS 2979 - WINDEV TUTORIAL 2 - 1.2- CRIAR JANELA E INSERIR TEXTO E EXIBIR
DICAS 2980 - WINDEV TUTORIAL 3 - 2.1- VARIAVEIS PARTE 1
DICAS 2981 - WINDEV TUTORIAL 4 - 2.2- VARIAVEIS ESCOPO - PARTE 2
DICAS 2982 - WINDEV TUTORIAL 5 - 2.1- VARIAVEIS OPERADORES PARTE 3
DICAS 2983 - WINDEV TUTORIAL 6 - 2.1.D - VARIAVEIS STRINGS PARTE 4
DICAS 2984 - WINDEV TUTORIAL 7 - 2.1.E - VARIAVEIS ARRAYS PARTE 5
DICAS 2985 - WINDEV TUTORIAL 8 - 2.2.A - CONDICOES IF-SWITCH PARTE 1
DICAS 2986 - WINDEV TUTORIAL 9 - 2.2.B - CONDICOES PARTE 2
DICAS 2987 - WINDEV TUTORIAL 10 - 2.3.A - LOOP PARTE 1
DICAS 2988 - WINDEV TUTORIAL 11 - 2.3.B - LOOP EXEMPLOS PARTE 2
DICAS 2989 - WINDEV TUTORIAL 12 - Lesson 2.4. The procedures - PARTE 1
DICAS 2990 - WINDEV TUTORIAL 13 - Leçon 2.4.b. Procedures Parametros - PARTE 2
DICAS 2991 - WINDEV TUTORIAL 14 - PROCEDURES REFERENCIA - PARTE 3
DICAS 2992 - WINDEV TUTORIAL 15 - PROCEDURES OPCIONAIS OU OBRIGATORIAS - PARTE 4
DICAS 2993 - WINDEV TUTORIAL 16 - PROCEDURES EXEMPLOS - PARTE 5
DICAS 2994 - WINDEV TUTORIAL 17 - PERGUNTAS E RESPOSTA - PARTE 1
DICAS 2995 - WINDEV TUTORIAL 18 - PERGUNTAS E RESPOSTA - PARTE 2
DICAS 2996 - WINDEV TUTORIAL 19 - WINDEV E OS BANCOS DE DADOS
DICAS 2997 - WINDEV TUTORIAL 20 - PROJETO E ANALISE - CRIACAO
DICAS 2998 - WINDEV TUTORIAL 21 - PROJETO E ANALISE - ARQUIVOS DADOS CLIENTE - PARTE 2
DICAS 2999 - WINDEV TUTORIAL 22 - PROJETO E ANALISE - ARQUIVOS DADOS CRIACAO ARQUIVO PEDIDO - PARTE 3
DICAS 3000 - WINDEV TUTORIAL 23 - PROJETO E ANALISE - IMPORTANDO CVS-ARQUIVO TEXTO - PARTE 4
DICAS 3001 - WINDEV TUTORIAL 24 - PROJETO E ANALISE - IMPORTANDO ARQUIVO PRODUTO - PARTE 5
DICAS 3002 - WINDEV TUTORIAL 25 - PROJETO E ANALISE - LINK - PARTE 6
DICAS 3003 - WINDEV TUTORIAL 26 - RAD COMPLETO
DICAS 3004 - WINDEV TUTORIAL 27 - VISAO GERAL
DICAS 3005 - WINDEV TUTORIAL 28 - Adicionar e Modificar Janelas PRODUTOS - PARTE A
DICAS 3006 - WINDEV TUTORIAL 29 - Adicionar e Modificar Janelas PRODUTOS Formulario - PARTE B
DICAS 3007 - WINDEV TUTORIAL 30 - Adicionar e Modificar Janelas PRODUTOS ALINHAR CAMPOS - PARTE C

















Lesson 7.9. The OOP
This lesson will teach you the following concepts
  • Concepts of Object-Oriented Programming.
  • Examples of object declaration.
  • Associated UML model.
Lesson duration

Estimated time: 30 mn
Previous LessonTable of contentsNext Lesson
Concepts
Object-Oriented Programming (OOP) is designed for better code reusability. The programs developed in OOP are structured: they include modules, each one managing a software feature. These modules can easily be re-used in other software. They group a set of procedures (called methods) and they encapsulate the data structure on which the methods will act.
To use object-oriented programming, you must declare classes, members and associated methods.

The classes

class contains the description of a data structure (the members) and the procedures (methods) that handle the members.
Therefore, a class defines a type of data and its behavior.

The objects

A class is used to create objects. Each created object owns the members described in its class and it can be handled via the methods of its class. An object is defined as a class instance.
When the class is declared, all you have to do is associate an object with a class in order for the object to be handled by all methods of this class.

The members

member is a data (or parameter) of the object.

The methods

method is used to act on the object, to modify its members for example.
A method is a procedure. Its operating mode is similar to the one of standard WLanguage procedures.

Concept of inheritance

The inheritance is used to include the characteristics of an existing class (base class) into a new class (derived class). The inheritance allows you to create a new data type from a known type in order to add features to it or to modify its behavior. Therefore, the base class will not be modified. A class can inherit from a class: it becomes a sub-class of this class.
The objects found in a derived class can access all methods, all members and all properties of ancestor classes; it is as if the methods, the members and the properties of ancestor classes were part of the derived class.

Constructor and Destructor

The notions of Constructor and Destructor are important because they allow for an automatic call to initialization methods when creating an object and when destroying it.
The Constructor method associated with a class is automatically called when declaring a class object.
The Destructor method associated with a class is automatically called when deleting the object (exit from the procedure where the object was declared).

Data encapsulation

The data encapsulation is used to ensure that the data belonging to the object is not accidentally modified by functions (methods) external to the object.
This allows you to prevent the user of an object from accessing some or all of its members. The members whose access is forbidden are called private members.
These private members can only be accessed from the methods designed for this purpose in the class.

Example

Let's take a simple example to apply these concepts:
  • Let's consider the PERSON class.
  • Florence is an instance of PERSON class.
  • The last name, first name and date of birth can be members of PERSON class.
  • The Age() method can be a method of PERSON class. It would calculate the age according to the "date of birth" member and according to todays' date (returned by DateSys).
  • Inheritance: A contact can be either a person, or a company.
    • PERSON could be a class derived from CONTACT.
    • COMPANY could be a class derived from CONTACT.

Creating an object-oriented program

To create an object-oriented program in WLanguage, you must:
  1. Describe the class and the class members
  2. Specify all class methods.
  3. Declare the objects by associating them with a class ("instantiate a class").
Simple example
  • To illustrate these concepts, we will use the example named "WD Simple OOP".
    1. Open the training example named "WD Simple OOP".
    2. Run the test of this example.
      WD OOP Simple example
    3. Click the different buttons corresponding to the animals in order to add them.
    4. Stop the example test to go back to the editor.Remark: We won't go into details about the syntax of OOP but we will present a simple example of an object-oriented program.

See Classes, members, methods and properties for more details.

Declaring a class

  • WINDEV allows you to easily declare the classes from the "Project explorer" pane. To create a class:
    1. In the "Project explorer" pane, select the "Classes" folder
    2. Display the popup menu of this folder (right mouse click) and select "Create a class".
    3. In the window that is displayed, specify the class name ("TestTUT" for example) and validate.
  • Study the WLanguage code of cSavanna class used in the example.
    1. In the "Project explorer" pane, select the "Classes" folder
    2. Open the "Classes" folder (to do so, click the arrow found in front of the folder name).
    3. Double-click the cSavanna class.
    4. The class WLanguage code is displayed in the code editor. The declaration code of the class is as follows:
      cSavanna is Class
       
      PROTECTED
      // Name of Image control used for the drawing
      m_sNameImageControlForDrawing is string
      // List of savanna animals
      m_arrTheAnimals is array of cAnimal dynamic
      END
      In this code:
      • "cSavanna" is the class name.
      • "m_sNameImageControlForDrawing" and "m_arrTheAnimals" are class members.
      • The "PROTECTED" keyword is used to specify that these members can only be handled from a code of the class or from a code of a derived class.

Describing the methods

  • WINDEV allows you to easily declare the classes from the "Project explorer" pane. To create a method:
    1. Right-click your class in the "Project explorer" pane.
    2. Select "New method" from the popup menu.
    3. In the window that is displayed, specify the method name and validate.
    4. Type the method code in the code editor.
  • To display the AddAnimal method of cSavanna class:
    1. Click your class in the "Project explorer" pane.
    2. Click the little arrow found in front of the class name: the different class methods are displayed.
    3. Double-click the method name:
      PROCEDURE AddAnimal(pclAnAnimal is cAnimal dynamic)
       
      // No more than 5 animals
      IF m_arrTheAnimals..Count = 5 THEN
      Error("No more than 5 animals!")
      RESULT False
      END
       
      // Adds the animal to the list
      Add(m_arrTheAnimalspclAnAnimal)
       
      // Draws the savanna
      DrawSavanna()
       
      RESULT True

Declaring and handling the objects

In the window WLanguage events, an object is declared at the same time as the other variables:
// Global declarations of WIN_OOP
PROCEDURE WIN_OOP()
 
// Savanna object
gclTheSavanna is cSavanna(IMG_Landscape..FullName)
To refer to a member of "cSavanna" object, use the following syntax
<ObjectName>.<member name>
  • In our example, the object is handled:
    • in the "Initializing" event of the window, to build the savanna.
      // Draws the savanna
      gclTheSavanna.DrawSavanna()
    • When creating an animal, to position the animal in the savanna.
      // Declares a new elephant
      clElephant is cElephant("Elephant "GetIdentifier(), 13)
       
      // Adds the elephant into the savanna (this action refreshes the drawing)
      IF gclTheSavanna.AddAnimal(clElephant) THEN
      // End message
      ToastDisplay("Animal added"toastShortvaMiddlehaCenter)
       
      END
We won't go into details about OOP in this tutorial.
UML diagram
The "WD Simple OOP" example is associated with an UML diagram.
  • To display the UML diagram linked to the project:
    1. Double-click "UML model" in the "Project explorer" pane:
      'Project explorer' pane
    2. The UML diagram (class diagram) linked to the project is displayed.
      UML diagram
    3. The different classes used by the "WD Simple OOP" project are found in this diagram.

Remark

WINDEV allows you to create the 9 types of UML diagrams.
To create a UML diagram:
  1. On the "Home" pane, in the "General" group, click "New".
  2. The element creation window appears: click "Architecture" then "UML".
  3. The UML model creation wizard starts, allowing you to choose the model to create:
    UML diagram creation wizard
We won't go into details about the use of UML language with WINDEV.
See The UML model for more details).




Teste

Teste
teste