WinDev 16 First Look

by Unknown user

In Installing WinDev I briefly describe the shipping product (WinDev, WinDev Mobile and WebDev) and went through the WinDev install process. At the conclusion of that process the installer offered to show me the tutorial, but I opted instead to spend a bit of time familiarizing myself with the WinDev concepts manual, with the idea that this would give me a better grounding in the WinDev Way. 

But before I get into the WinDev concepts I think it's worth looking over some of the key features of the WinDev environment. 

WinDev features

WinDev has a rich feature set - this is a product suite with regular upgrades. First released in 1993, winDev is now on version 16 (version 17 in the French language version). That's very nearly one major version per year, and if recent releases are any indication there are quite a lot of new features added in each release. 

WinDev is one of three major development products, and provides support for desktop development on Windows with deployment on Windows and on several x86 Linux distros (with some limitations) including, as of March 2012, Debian 5.02 and Ubuntu 10.04. 

Similarly, the WebDev product lets you create applications that run on either Windows or Linux, and the WinDev Mobile product creates applications that run on a wide variety of smartphone and tablet devices (WinDev 17 adds iPhone/iPad support). 

The key in all these cases is PC Soft's generalized W Language, with which you can create applications that run on native Windows, .NET or Java. 

Although there are three main products in the PC Soft line, in this review I'll focus on desktop development using the WinDev IDE, which is shared by WinDev, WebDev and WinDev Mobile. 

Other significant features of WinDev include:

  • Documentation management and generation
  • Source code management and sharing
  • Built-in SQL engine
  • Support for mainstream SQL databases
  • Reporting (with support for email, PDF, HTML etc.)
  • Application testing & quality control (bug tracking and incident management)
  • Profiling
  • Static code audit
  • Requirements management
  • Developer task managment
  • User interface styling/skinning
  • Extensive set of window and report controls
  • Charting
  • Touch screen support
  • Ability to integrate Java, C++, C#, VB and other languages
  • Integration with Word, Excel, OpenOffice
  • Build automation/continuous integration
  • UML modeling
  • Web services
  • 3 tier architecture
  • Application security (user groupware)
  • Internationalization/localization
  • Ability to import windows from other applications (see webinar #2 at wxlive.us)
  • Multiple configurations for the same project (different target operating systems, web services, etc)
  • Deployment
  • Many images of scantily clad young women
I only bring up the last point because PC Soft's marketing materials are in fact loaded with photographs that some developers have found a bit incongruous, and which sometimes make it more difficult to take the product seriously. The provocative graphics are largely absent from the technical documentation. 

The concepts & tutorial manuals

The two main sources of information for new WinDev users are the Concepts and Tutorial manuals. The Tutorial is a much larger document and dives right into the specifics of creating and manipulating windows, then working through controls, databases, SQL queries, reports and various advanced topics. 

If you have significant development experience, then the Concepts manual is probably a better starting point as it provides an effective 50,000 foot view of what WinDev can do.

The Concepts manual

The Concepts manual is a relatively svelte 200 pages and covers the following topics:

  • The development process
  • Windows
  • Window templates (predefined window layouts)
  • Controls
  • Control templates (collections of window controls that can be reused)
  • Reports
  • Report templates (predefined report layouts)
  • WinDev editors
  • Generating code for multiple platforms. 
  • Project and source organization
  • Components
  • Business rules
  • Databases
  • UML
  • Internationalization/localization
  • Reports and queries
  • Debugging
  • Unit testing
  • Installing apps
  • Communication (email, FTP, sockets, web services)
  • Supplied components and examples

That may seem like a lot of the same material as you'll find in the tutorial, but there's an important difference. The tutorial is geared toward teaching both programming and WinDev, while the concepts manual assumes programming knowledge and focuses on explaining all the different ways WinDev supports the development process. 

And there's a lot to get to know. 

Figuring out the IDE

The WinDev IDE can seem a bit cluttered and confusing at first as there's so much going on and there are a number of different ways to view your application. 

There is a centralized view called the Project Dashboard - if you don't see it you can choose it from Project | Project Dashboard.

WinDev is designed to be a full-fledged project management system as well as a programming tool, so you'll find indicators on the dashboard of the overall "health" of your project. The above screen shows the dashboard in Developer mode. You can also switch to Project Manager mode to get an overview of project requirements and their status. 

Some of the tasks you can do from the dashboard are:

  • Run tests
  • View bug reports
  • Update shared components
  • View compiler errors and warnings
  • Go to analysis (i.e. the data model)
  • Go to UML diagrams
  • Get project statistics
  • Run various kinds of analysis on the project code
  • Run tests
  • View program elements/components

The quick start - creating an application from a database

Like Clarion, WinDev has the ability to import a database and generate a fully functional browse/form style application. I began by choosing File | New... and choosing Project. This brought up the project wizard.

I made this a Windows application. 

It's possible to defer the choice of platform until later.

As WinDev has project management support built in, I had the option of providing an estimated delivery date. 

I selected a single user rather than a team environment, and then had a choice of charters

A charter is a set of prefixes automatically attached to different kinds of functions and labels - think of it as a built in naming convention. There is just one predefined set which you can see by clicking on the Edit button:

There are naming conventions for project elements, window, page and report controls, and also for variables, where you can specify values for variable type and scope. These naming conventions apply to anything WinDev creates for you. 

I'll skip some of the screen shots for the sake of space - there are a number of visual styles you can choose from, you can specify preferred and maximum window sizes, as well as internationalization/localization options. For the latter a wide range of language support is built in:

And at last, the database. I wanted to use an existing PostgreSQL database. 

I didn't have an existing analysis for that database (in Clarion terms, a data dictionary) so on the following screens I indicated I wanted to import my tables from the database. 

When it came time to choose my database I selected PostgreSQL, but as the selection window scrolls (I'm showing it here in its entirety) I missed the fact that I could select multiple databases at once, and that the default HyperfileSQL Classic database is already selected. So I had to go back and uncheck that option. 

For Postgres there are two connection options: Native and ODBC via OLEDB. I had some trouble using the ODBC route (perhaps due to configuration problems on my end), so eventually I downloaded and installed the native PostgreSQL access module, and that worked. 

After supplying connection data I had another choice: whether to keep the data in PostgreSQL or import it into HyperfileSQL. I elected to keep the data in PostgreSQL.

The wizard then showed me a list of available tables.

There's also a nice little "Preview the data" link that will bring up the records for the selected table. 

I chose three related tables, but which did not have the relationships defined in the Postgres database. WinDev created a database diagram:

which was immediately overlaid with an application wizard.

I clicked on Full Application RAD and was presented with a further choice of RAD pattern. There were five of these, four of which offered varying degrees of animation and other flashy effects. I went with Simple RAD. 

Next I had the option of selecting files for generation:

I left all selected. A similar screen appeared asking me which files to use as main menu items. Again I stayed with all files. 

Did I want to add groupware? This is the WinDev user management system. I declined. 

Next, a help (or ?) menu. 

That seemed like a good idea. I accepted the default entries for the ? menu:

WinDev offered to generate the help file automatically. 

There were various other ? menu options to address, and when that was done WinDev chugged away for about ten seconds (generating the app, I believe) and then presented me with some help file generation options. I elected to skip help file generation. 

WinDev then compiled my app, and found a number of GUI errors related to my my decision to include two additional languages. These errors were primarily for radio buttons or check boxes not having captions in one or more languages. 

On the Project Dashboard I clicked on the languages button and removed those two languages. When I clicked OK WinDev compiled the app again. Now I had just three errors, still related to the languages. 

This was due to a too-narrow report column, which I easily fixed by double-clicking on the error and changing the size of the column, which conveniently had its grab handles showing. 

I ran the program by clicking the Go icon. Nothing too fancy given my choice of Simple RAD:

Each menu provided two items, one for the list and one for a new record form. Here's the articles list:

In the database all my labels are lower case, as having mixed case labels in Postgres means you always have to refer to them in exactly that case. (It's one of the few unpleasant quirks in what is otherwise a massively useful SQL product.) 

The update form is similarly plain.

 

By default at least, WinDev creates SDI applications, although MDI is supported. For SDI you have the option of automatically dimming all windows other than the active window. 

Within the listbox each of the columns is sortable and searchable. Click on the up/down arrow to sort and the magnifying glass to search. 

Right-clicking on the listbox brings up a context menu that allows you to select columns to display, copy data, and export to Word, Excel and XML. 

There's a charting option as well, but it only appears to work on the first 50 records. Perhaps that's configurable. 

You can also dynamically add calculations to numeric columns: sum, count and average. Thse will be added to the bottom of the column. On large data sets it can take a while for these values to appear. 

All of which brings up the question of paged data retrieval. Clarion developers are accustomed to paged data retrieval, which brings the benefit of better performance on large data sets and introduces many complications when you want to do things like totals on data not entirely in memory. By default WinDev, like many other data retrieval tools, just brings back whatever you tell it you want, so it's up to you to use appropriate filters on your data sets. I'm told there is an equivalent to page loading available within WinDev, although it has some limitations. You can also build your own paging support, if you wish - Unknown user has demonstrated this in a WxLive webinar

Just for fun, I regenerated the application using the Antakara pattern and got something rather different. Here's a browse with an open form (note that the browse is automatically dimmed):

The Ankara pattern adds a calendar, a ToDo list, and some graphics as standard equipment.

Embed points

Like Clarion, WinDev lets you insert your own code into the generated code. Just right-click on any window or report and choose Code...

You'll get a view that looks a bit like the Clarion embed editor. In this screen shot I've pressed F6, which shows a sidebar with the initials and date of the latest source change. This can be very helpful in a team environment when you're trying to find out who made a change and for what purpose. 

By default the code view shows available code points for the item on which you clicked (window, individual control, etc.). You can toggle the display of all code points with Ctrl-F6 or via the Code menu. 

Reports

The report design also bears some similarity to the Clarion designer. 

To add a new report element, right-click at the desired location on the report and choose Add a block:

Then choose a block type:

You can also add sorts and breaks:

Code reuse

One of the most important aspects of modern application development is code reuse. Naturally, windows, reports, and their associated code can be reused. But you can also create smaller and larger units of reusable code.

An "internal window" is a window that you can use within a control on another window. The internal window and its code is merged into the window where it is used. 

There are also several kinds of components you can create, internal and external.

Internal components are collections of windows, reports, procedures, etc which you can put into the source code repository for reuse within your applications. When you use internal components they become part of your project's code base.

External components are analogous to third party DLLs. They don't form part of your code base, but you can use them however you like. 

Testing

WinDev has built in support for various kinds of testing, including recording and replying interactions with the user interface as well as some degree of automated unit testing for classes and other code you write. I haven't yet tried out any of the testing capabilities, but I hope to soon. I'm a huge fan of automated testing; being able to run tests as part of the build process makes it that much more likely that you'll trap regressions before they get to the client, and also makes adding new features to a product that much safer. 

Summary

It's easy to see why WinDev appears to Clarion developers: it offers a fast track to working applications, it deals effectively with a wide range of databases, and it allows for a high degree of customization. At the same time there are some significant differences. Clarion is in some ways a lower-level tool; critically it provides detailed access to the code generation process via the template system, letting developers and third party vendors customize to the nth degree. WinDev hides more from the developer; the code generation and compilation process is inaccessible, the application generation environment is less customizable. On the other hand WinDev is a more polished product with numerous features that enhance individual and team development, with more comprehensive support for web and mobile development. 

WinDev's API is massive, with a steady stream of additions and new features in each release. Cross-platform support is included, with some limitations (not all W language capabilities are available on Linux, for instance, or on all mobile platforms).

WinDev has long been a popular choice among French-speaking developers - I'm told that during the company's "Tour de France" gatherings in individual French cities can exceed 300 participants. WinDev has historically not been as popular among English-speaking developers, although that seems to have changed in recent years and with WinDev's release numbers getting into the mid-teens. 

An express version of WinDev is available for download. The full version of each WinDev product is €1650, or €4950 for all three, but a 40% competitive exchange discount is currently available. See the list of WinDev Resellers for your nearest dealer.