|
UK SMARTWARE USER GROUP, February 1999 PAINLESS WINDOWS Is it possible to develop Smartware into a Windows environment. Developers are constantly coming under pressure to provide the windows front end, usually to products that are already well designed in Smartware. The tools to accomplish this previously complicated feat are now arriving, taking away the pain for plenty of gain. It is a fact of life, or so it seems, that everyone thinks they need to use Microsoft software tools for absolutely everything. The Windows operating system interface does provide for standardisation to users, but I find that this comes as a cost, namely performance. This I find unacceptable, after all if something performs well then it's the software I want to use, if you can make it look good too then even better. That software can be Smartware 2000. We are all aware that Smartware has never got rid of the `dossy' appearance. It is also true to say that out of the box it only goes a short way to providing Windows compatibility. Recently as a result of hard work and ingenuity on the part of users have begun to bridge the gap between performance and prettiness . How can it be achieved - that's the question I hope to answer with this article and demonstration. At the last SMUG meeting Chris Anderson of CJ Computer Services gave a very useful and informative demonstration of Rocky Scofields, Smart Designs - the user with the ingenuity and talent that developed a perfectly useable front end to Smartware in the Windows environment.
The SWAPI library makes it easy to achieve many windows effects from a Smartware front end, it is now no longer the domain of the C++ programmer. The library as it stands consists of 39 functions that are useable in a 32bit Windows environment (Windows 95/98/NT). Some of the functions are specific to a particular operating system. Details of the these can be found in the manual. As an example of what it takes to call the format disk dialog box via Smartware normally, the code is shown below; FUNCTION _fmtdisk(drive) This is not for the faint hearted. Jason has kindly reduced this to the following Smartware command, much more palatable. EXTERNAL FORMATDLG() I have been using the SWAPI library for a few days now and I have to say that I am impressed. The library is compact, SWAPI.RF3 is just over 10k in size, and can be loaded in any ANGOSS module. The functions cover a number of areas, namely multimedia, system access, program execution and the internet, just about all of WIndows really. Some of the functions that have been long sought after are also included, the ability to launch an external application for example monitoring the program until it closes, thus preventing ANGOSS completing other tasks while the external program is running. Here is an example taken straight from the manual, which launches notepad and waits for it to close before continuing. EXTERNAL PROCESS_START (1) From my short time using this product I can say that it appears to be robust and does exactly the job it set's out to do. The accompanying manual is also well documented and contains an example for every function. The cost of the product is going to be $200 canadian dollars, which I am told equates to about £75.00. This really does represent good value for money and compares well with the products marketed in the early 90's by the likes of Microart Consultants. Further information and details of availability can be obtained via e-mail from jason@baldhead.com. Windows integration doesn't have to end there. If you have access to products like Visual Basic, there is nothing stopping you writing small programs that you can launch via Smartware to carry out different task's. This is the method I used extensively until the availability of the third party addons previously mentioned. A good example of this approach would be the `printbox' system developed by Jason whilst at CUSP. This program, launched via Smartware could change the Windows default printer to allow faxing and such like to take place, and return the printer settingsd to there original state when finished. I use similar programs to scan subdirectory's to establish the availability of data files. By `executing' a windows program as opposed to a dos batch file in a command shell the Smartware screen remains intact and doesn't flash to a black DOS screen as the commands are executed. Visual BASIC also plays a part in our Crime Management System searching module. The Smartware half of the system is 'vbsearch.rf3', which I hope is pretty self explanatory; The VB program is written using Visual Basic 6 Pro., and displays the calendar control. All the VB programs will require that you have the `msvbvm60.dll' runtime libary installed in the `path' of your computer. The VB program and accompanying OCX file (calendar control) must be installed into the directory of the Smartware system you wish to use it with. Using the program is straightforward as you will see.
Another application utilises a VB program to monitor the network for software changes to a particular system. The program is triggered by changing the details within a version.txt file on the server. Our client program, which launches smartware applications checks the local copy of the version file against that which we may have changed on the server. When a difference is detected a complete copy of all the server based files is made to each client machine. This method provides a neat and efficient way of keeping each system up to date with the latest developments. The `version.txt' file contains a version number and date which can be seen on each client in the bottom left corner (see the calendar program screenshot) Shortly we will be taking delivery of our copy of Smart designs and SWAPI. These tools combined with VB and Smartware itself provide a bright bright future for a product that started it's days in DOS. There aren't many products about these days that can say that they have been around that long ! With the dominance of Microsoft on the desktop you cannot ignore the technologies that are moving the computer industry forward at a phenomenal rate. One such technology may revolutionise the way in which Smartware data is handled. Thanks to the advent of ODBC, Smartware and other types of data files can be accessed through different front ends. One such front end that I have started to experiment with is Internet Explorer. It is possible to use Windows NT4 Server to provide an interface between Internet Explorer and the ODBC data source, i.e. your data. This technology is called Active Server Pages. Active server pages is a programming/scripting language that is very similar in origin to visual basic. ASP passes requests from IE4 to be processed by an ODBC back end database, much like a query. ASP interrogates the query and generates an HTML (Hypertext Markup Language) page `on the fly'. The results in this page are displayed to the client making the request via internet explorer. A standard front end across all your datasets is achieved. Easy to learn too !, it took me one weekend to get to grips with simple searching, SQL (Structured Query Language) and my data to provide a simple interface to some crime data in a Smartware database, the results are shown below. As well as using add on applications that provide a windows front end to Smartware, there are many good tools (some of which can be found on the SMUG library disks) that can make the developers job easier. Users of Compuserve will have seen `minitrue' which was a DOS based product that allowed search and replace across multiple files. How about using Programmers File Editor to edit your Smartware programs, no limit on project file size with this. `PFE' has the ability to then launch smartware and compile the project file for use in ANGOSS, not to mention cut and paste capability something I miss in ANGOSS. Another of my favourite tools is `examdiff pro' which highlights the changes between different directories and project files. This program is in use constantly to monitor changes between similar project files across different systems. ADDING CLIPBOARD FACILITIES, Alan Salmon |