WebDev and my first PHP project
Let me preface this with, I am not a graphic artist, I am color blind, (shades) and I get REALLY , REALLY frustrated when it comes to the web and trying to build a simple set of pages to be used.
One thing I will say is Bruce from Capesoft has built an excellent tool to generate webpages. I like it it runs well; only issue is you basically need to have a virtual server, or your own since it runs using an EXE, while that may not be an issue, and not overly expensive, BUT I have had an unlimited account with hostexcellence (www.hostexcellence.com) for several years for 85.00 per year. So what’s this saying? if your TPS, or have a CW application you need on the web, contact him….
Now for Windev’s WEBDEV Product. NOTE (remember first sentence)….. I modified the CCS MSSQL Managment program to send data to Mysql because the web actually works well with PHP, and mysql is native. I choose PHP over the AWP (webdev’s own) for the same reason as I didn’t use the Clarion product; it uses a EXE to manage the pages and that isn’t allowed on the hosting I have. also, with PHP, once I got the main pages developed, it can be updated/ made slick by the graphics person, or maintained from there outside of webdev if needed.
Overall, I spent 3 days reviewing and asking Glenn Rathke a few questions (www.sdcdev.net) and I spent about 12 hrs getting it to work the way I wanted it to… for the web programmers out there, I know, 12 hrs? well, being realistic, this is a FEAT for me, I wanted a certain methodology for the screens and how they reacted, took a lot of small modifications, I cannot test locally since I don’t have it setup correctly…
couple things PCSoft should do, check better on the files for changes in the deploy program, inevitably I would make a change and would manually have to find it in the list to send it, also couldn’t find a PHP tutorial with distribution to show how to do several things.. now that may have been me , and I understand they want to push thier own products.
Either way, I managed to get it working well, it runs on my zoom as well fantastic…. if you wish to take a look www.dbamonster.com , I can now do websites in PHP without screaming and pounding my head into the wall….
THATS GREAT!!!!!
Andy
Happy Turkey Day!!!!!
Just wanted to let everyone know , Happy Thanksgiving, as we go through life looking at the struggles we have to go thru, this is one time we all need to stop and be thankful we are where we are, and realize our struggles are minor compared to some others.
Posted a New version of the CCS MSSQL Analyzer (ccs Lunchbox Page), will give you 16 different views and hints on how to tune your database and allow it to perform as you expected.
have a great weekend
The BuildBrowsingTable Feature of Windev Tables.
Wow, Wow… I know quite a few of y’all out there already know of the BuildBrowsingTable , but from my ole CW days this is refreshing to say the least….
Ok, so no more defining the Dictionary Elements, no more compiling the Files DLL, and then no more Local vs hot fields yada yada @#$@# any more…. From a SQL statement standpoint some Absolute flexibility in displaying data without having to go through all of the efforts and chores….
Lets take a look…
A couple of tricks along the way…..
when you Drop the Table control on the screen, use one Field I called my QUERY so the header had that in it, if I retrieve no data, then I can put “No Data Found” in the field using TableAddLine(Table,”No Table Found”)
otherwise, it will take the layout of my select statement and display on the screen as simple as the following:
Below is the statement, we use the AS [] to alias the field name to a more descriptive nature for everyone to see, I can put in there any combination of information inner join, outers function calls whatever is needed. Also you see the use of [] for the SQL statement presented, and using the %1 , %2 for variables sent. (will go over that later).
dsStat is Data Source nNDX is int = 0 SqlStatement is string = [ SELECT st.text AS [Parent_Query] , DB_NAME(st.dbid)AS [DatabaseName] , cp.usecounts AS [Usage_Count] , Convert(Varchar(MAX),qp.query_plan) as Query_Plan FROM sys.dm_exec_cached_plans cp CROSS APPLY sys.dm_exec_sql_text(cp.plan_handle) st CROSS APPLY sys.dm_exec_query_plan(cp.plan_handle) qp WHERE CAST(qp.query_plan AS VARCHAR(MAX)) LIKE '%<ColumnsWithNoStatistics>%' AND DB_NAME(st.DBID) = '%1' ORDER BY cp.usecounts DESC ] IF HExecuteSQLQuery(dsStat,DBConn,hQueryWithoutCorrection,StringBuild(SqlStatement,Glo.dbName)) THEN nNDX++ HReadFirst(dsStat) TableDeleteAll(Table_Statistics) IF NOT HOut() BuildBrowsingTable(Table_Statistics,dsStat,taFillTable) ELSE TableAddLine(Table_Statistics,"No Missing Statistics Found") END ELSE Error(StringBuild(SqlStatement,Glo.dbName)+ " " + HErrorInfo()) END
IF the records are found, you get the BuildBrowsingTable() call to fill the information on the screen.
If no data exist you get
if The data exists then you get :
This gives you quite a bit of flexibility with the data, and you can still edit/change it because it uses _Col1, _Col2 for each field match up to your statement and you can quickly program based on the results.
All I can say, is I like this one… and it will be in my toolbox for quite sometime.
Version 16 Scheduler Control
While I am no expert at windev as yet, I am in the “Learning curve” of what is needed/available and capable of this language and environment provided, and I am getting impressed.
The new Scheduler control is one of those items that for the most part (as far as I have used it) been quite a refresher from other offerings, where as your 90% dealing with your code vs dealing with all the windows events, functionality and items that you would normally code in order to accomplish what comes out of the box here.
To go over the control and what I am doing , I will give a bit of background first… We use MSSQL as a database, where we have workorders and quotes for customers, this is a Legacy application that has been in development for over 10 years and has not been moved to ABC previously in CW. So in order to give a clean, good looking scheduler that the customer can use I have chosen to develop in-house windev application that we can use 2 ways:
- Standalone EXE for viewing as well as management
- Dot Net DLL, that can have a COM wrapper to be called from CW when needed
- WDK component for possible future conversion of application to windev
We store quite a few things in the Scheduler variables to be able to anticipate needs so the use of the “appointment” Variable provided. This gives us good flexibility over the original appointment from the Organizer control. “Resources ” is the key here, Resourse’s allows you to specify items along the left side or across top of different personnel, area’s in a business as Resource Assignments for appointments.
Fig 1.1

I also created a GLOBAL structure to hold the information, that way instead of using quite a few lines of code, the global variable holds the appointment and we can update as needed. there are several events in the control we will be using; as you can see there are 2 toolbars for managing the scheduler from both the view of the scheduler as well as appointment updates. In the code section of the control we are putting code into the SELECTING, MOVING, RESIZING, DELETING, and REASSIGNING appointment Procedures, and place the following code in the Procedure area of each code section.
Selection(aptSelect is Appointment)
Glo.Appts = aptSelect
FetchCustomer(Glo.Appts..ID) // ID is the primary Key of the appointment in the database
As an example if you select an appointment then click the toolbar for “Confirmed” you would have the appointment in the global variable, and be able to modify the appointment with a different icon and status. I used Category in the appointment to store the current category of each appointment so for our example we change the Category to “Confirmed” in the following code snippet.
IF Glo.Appts.ID > 0 THEN //make sure we have an appointment at all
Glo.Appts.Category = “Confirmed”
UpdateAppt(Glo.Appts)
END
There was a couple issues I ran into , but haven’t fully resolved, I certainly wished that windev would allow you to specify more than one ID field for the appointment variable, a ResourceID would be great as well as an UPDATE for the appointment/Resource as they give you methods to add/delete but not update the information.
In order to get around that situation. we use SchedulerListAppointment to Locate the appointment, use SchedulerDeleteAppointment to remove the outdated version and SchedulerAddAppointment to re-add it.
This is all done using the following type SQL statement
sQuery is string = [
Select USE_UserID,Mechanic,pAPPT_SysID, pAppt_PeopleID, pAppt_MechID, pAppt_TransID, pAppt_DetID, pAppt_StartDate, pAppt_Enddate, pAppt_Title, pAppt_Content, pAppt_Note, pAppt_ToolTip, pAppt_category, pAppt_Importance
FROM DBO.vw_mechanicList
Left Outer Join DBO.PeopleAppointments on pAPPT_mechID = USE_UserID
]
Code wise there was bout 20 hrs spent developing the entire scheduler and appointment view with current abilities. not bad for first itteration , not really knowing what I am working with and learning windev as well . Feature wise there is quite a bit here, that I don’t have to deal with at all, the resizing of the appointment , moving from one resource to another, changing the information is all quite simple.
NOTE: they did provide a File capability to the scheduler, the only reason I didn’t use it is because of the Icon changing on changing the Category (status) of the appointment. I am sure with some more tinkering I could get that better suited, but in my testing , It cause some flashing on the rebuild of the appointments I didn’t like.
Again, this is a “Beginners” perspective of use of Windev in a real world environment. and it works well, remember if you use MSSQL our CCS MSSQL Manager is a service written in windev that automatically manages efforts in MSSQL and will be updated with some DBA informational items to manage full scale server installatiosn soon.
Andy <<Cowboy>> Stapleton
MSSQL – Managing the effort
I know I have been missing for awhile, been hard at working on several things, SOAP servers, Droid applications and such. So forgive me for being absent and I will make it a point to put out a blog each week. This week lets talk about MSSQL, Windev and Services.
Small business has had a friend in Microsoft for a few years now, with the free MSSQL , and now with MSSQL 2008, you can virtually run a small business with it, and many do. Small to medium Software developer business’s have developed software using MSSQL and distributing them to clients now for several years. Over this time I have seen quite a bit of different databases, some in pretty good shape, some not so good, and those that is used quite a bit; with no RI and basic indexes only.
Yea, I know MSSQL has said ” it is built so you don’t need a DBA” , and in some ways that is true, for the most part MSSQL runs and attempts to keep up, till your business grows and you wonder why your software is running slower and slower, till you almost fed up…Not so fast… While it is free, and can scale, the process of maintenance still is not automatic even in MSSQL 2008 , fragmenting of indexes, Locks, knowing what indexes to have and not have, statistics and even when to use Hints or not come into play.
Some of the items that needs maintenance in MSSQL:
- Index Fragmentation
- determine Index needs/ create/ drop as needed
- log file maintenance (shrink)
- diskspace / memory requirements
- slow statement executions
- Statistics management
If you have a small business that runs on one of teh MSSQL flavors “Express, Small Business, Standard.Enterprise” these tasks have to be done . In order to keep up with these tasks, you can spend hours going over books, google searches, and training to find the scripts to do the above job, pay couple thousand for software to monitor your instances, or periodically hire a DBA to come in and do it remotely.
Clarion for windows with a hack from a company out of South Africa managed to create services that could be used on servers, but in all the ones created, using MSSQL Lockups would occur, wouldn’t keep connections locally, couldn’t post easily to the event log to see issues, just a myriad of small issues kept me from spending the hours getting past all these issues.
Then along comes windev, in version 15, they now create services, I have created now 5 of them, they all work well, in fact, I have yet to experience any of the problems that have occured in the Clarion versions… So finally in an exercise on the new development platform I wrote an extensive service that handles these jobs above, I always said “if the computer can do it, then I don’t have too” ;
There are 2 products on the CCS Software page, http://www.ccscowboy.com/?page_id=82
CCS Analyzer — allows you to manually see the issues and correct them on any database you can connect to.
CCS MSSQL Manager – manages the above issues and reports to you once a month what it has done, runs as a service on the MSSQL Server, for one or more databases depending on level purchased.
I have been using this and a few friends testing for now almost a month and each have reported excellent results, so now I put it out for everyone to try, use and keep the performance without the excess cost of some tools out there, or hassle of manually maintaining them.
In future releases, I will be adding things like:
- Validation of SQL procedures / views – look at each and give you report on how to create them more efficiently and minimize locking.
- TOP number worse SQL statements – review of statements being generated and recommending changes.
- OPTION to automatically kill Deadlocks if they occur.
- Lock Escalations to let you know what process’s Kill your performance
Enjoy and stay tuned for more…
In Defense of Languages
Over the years in Clarion, I have been guilty, as well as observed hundreds of posts, where languages of other environments are eviscerated, entire development environments are trashed as well as the simple “But Can it do this in this timeframe”. After watching, being involved, with these threads over the years; well I am finally on the other side, while some cannot understand, some are listening, and others are only going to bash the “other guy” because he speaks out..
A bit of history(one of the first fits posted), When CDD 3.0 came out, there was the original CW 2.1 bunch in the Old forums, CDD was a leap foward in technology for Clarion, changes in Templates, changes in languages and the starting of the “new version” of where CW 1.0 would go. Quite a few CD 2.1 folks where angry over the changes as they didn’t fall into or had issues with how it was done before, there was 3rd party tools that took advantage of the shortcomings of 2.1 that would no longer be needed in 3.0. CDD 3.0 did have many issues, bugs , had to work around issues as well, causing hundreds of messages on the forum that it was crap, trouble, and “why can’t we stay with 2.1?.
Obviously the market was moving foward, Topspeed at the time was attempting to move foward with it, they had started Developers conferences, looked at developers for input towards industry needs, as well as took advantage of the assistance that the developers moving with them into the future provided. For quite some time, you could see the “old timers” leaving and sticking to the 2.1; Industry moved forward and along comes win 95, Cw 1.0 and the Windows environment, some challenging times to say the least, Watcom was there, fixing to be sold to Sybase, MSSQL was crap 7.0 and Oracle was the big player along with DB2.
It was challenging to say the least to determine where issues where during that time, whether it was Windows, CW or what was causing errors, bugs and “blue screen of death”. But AGAIN Topspeed was there, working with the “Team Topspeed” to get thru issues all the way, it was something to hang on to, a lifeline building a community of like minded and helpful developers that would insure CW successful future for quite a few years..
Time progress’s, other challengers to “Topspeed’s “ methodology , have arrived, Windev , Alpha 5, Visual Studio, other code generators ; each of which have had it’s advantages , disadvantages as well as the Threads in the forum of “how bad it is” because it doesn’t have templates, doesn’t do this or I can do it also no problem as long as I hold my tongue just right and you only run it on my machine… each Trashed and discounted until the individual leaves, and goes away, tired of fighting against the “community wave”. I too had been part of that group, figuring out ways to accept CW limitations and tell myself that Topspeed would at least get close to current “industry standards” and the 3rd party market will fill in the blanks; sadly the players of Topspeed pulled the plug, sold the software and realized that frankly there was a end-game and it was drawing near.
Now we come to the last 5 years or so, New company, new hope, forward progressive views, new IDE 64 bit; new template language changes, new Language CW#, again hope that SV “gets it” and will start to catch up to market pressure and deliver a product that not only provide “ALL” the functionality we had since CW1.0 but leaps ahead in abilities to use technology in the future.
For 3 of those years, I and other’s patiently waited for the 64 bit IDE, with all the grand features, friends where on the C7 path, I chose the CW# path as after working with C# for awhile, the advantages of what CW# could provide in templates and abilities could be the “Leap ahead” in technology.
But the truth has been self-evident, with SV lack of “involvement” with the user community, the inordinate amount of time it took to produce CW7 , the first release of the new IDE being so buggy as to be unusable; and frankly from the chats in Skype even after 7.3 release Still issues are occurring to developers; throw that in that in FACT NO REAL progress in the CW language in the move to the IDE!, So what did we actually get? We got a new IDE, some Productivity changes and enhancements according to others, but basically still generating the same code as prev versions. no 64 bit compiler to provide 64 bit executables, no Source code Management, no Bug Management, no tight integration to the windows memory model, no enhancements to the controls, as this progressed, I keeped seeing others disappear from the newsgroups, people I have seen posted over the years slowly fade , or only in the “public chat” area, new developers where sparse, no real influx of people, contracts and Jobs newsgroups slowly fading in posts, or posts where “convert CW to VB, or C#” , In other words the “Writing was on the wall”.
I was actively involved with learning CW# actively involved with attempting to get this working, reports work fine, really didn’t change that much, language constructs different but workable, patiently waiting to see and use the template language to generate, work with and produce fast , maintainable code; after 3 years, still don’t see it yet. No real gain over C# as the only pieces that make it workable is the Table, or list box and file access portions.
So as a pure business aspect you really have to ask the questions;
- with the industry being a Lifetime of changes each 3 years, can CW or CW# catch up.
- is SV with dwindling developers, dwindling resources(???) capable of putting in the funds to do it.
- is the release of CW# going to have same issues as the release of C7 and cost another 1600 to get straight as releases get “cooked” till at least medium rare.
- what other technical problems will you run into?
- Will there be Jobs/Contracts to make a living on it?
- If it came out today, HOW long would it take to convert a commercial app?
- Can you afford the time to convert from CW to CW#?
In my opinion there are too many unknowns; so should I as a developer keep riding a tired horse, that will soon possibly die?
So the research begins; in my first blog I listed the items I was looking for, I have looked at several code generators as well as environments to find the results needed. Can I develop in “low level” languages, sure, but do I need to, remember goals are to provide an interface to the data for the customer to get the information needed. Past that, give an interface that shows modern “look and feel” and is rock solid in usage.
I personally believe I have found it, in windev, quite a few Ex-CW are here, as well as windev has not “closed the doors” to outside items(or made it difficult) such as Dot net , Java, Soap, XML, SAP,J2EE, and RPC(all included in native environment); including generating and providing Dot Net DLL to other environments as VS. Development for Linux and windows, pure java applications as well as I can develop a Droid app.
So unlike other counterparts that have faded away in the CW forums, I chose to let my fellow CWers know, there is an “viable option” out there other than CW, that literally produce 500 new features in the new version 15. Obviously the vitriol posting and fussing began, a repeat of CDD 3.0 , CW1.0, and prev; the difference is , no future, no hope, no SV involment into the community (except for deleting derogatory messages), no Team SV, no way to build or create the “Community” aspect that has kept CW alive for so long.
So Where do I see CW?
The current CW language as a windows development, maybe 3-5 years, as Cloud computing and other interfaces are created to a more data-centric environment gain traction, CW will continue to lose market share, and fade, as it fades the company out of sheer necessity will abandon or set it aside like it did CDD or CD2.1 leaving all those programming behind.
CW# — good question here, but the longer it takes to provide a viable environment, language, and Appgen, the further behind it will get, add that to new Dot net capabilities being added every few months it can be daunting for a small operation to keep up let alone finish or get ahead. It HAD the best opportunity for the future of CW, and also the most difficult to achieve. Steve Ryan BIG promoter of CW# , gone, no messages since 2008 in the winforms C# forum, frankly other than the occasional “where is it” message , hardly any messages.
So your left with the difficult question: Shall I still put my future 5 years from now into CW and CW# and SV or not?
That is your choice, I have chosen to work in CW with a wonderful small company and look to convert to something that stands a much greater chance of being here in 5 years.
Of course , you can discount this blog as “Ranting of a disenchanted developer”, and in some ways your correct, I am disillusioned, and need new excitement, but after close to 15-18 years of CW development, a reputation of helping others as well as being a “bulldog” on occasion; to abandon the community without discourse on what is out there, better or not, would lay heavy on my conscience.
So what is my biggest hope? Some one with the stature of Stamos gets back involved and proves me wrong, as it stands current “chiefs in charge” have not.
If you don’t agree, fine, hopefully I am wrong, I just don’t think I want to bet my future on it..anymore…….
Andy <<Cowboy>> Stapleton
Analysis (Windev DCT).
Lets go over the analysis area of Windev…
Now for the most part, I have already defined everything in MSSQL, I don’t use constraints as far as relationships , I use triggers on the DB level to maintain my DB integrity.
What that means is the analysis is mainly a layer to allow the development to access the field elements in the DB, so the preface of this blog is based on MSSQL, or MySQL (frankly any SQL DB) vs a more standard file structure that requires you setup relationships and items inside the analysis.
As with all these type items, it should be a “Repository” , a long time ago I had been looking at Powerbuilder and ran across the idea of a “Repository” , a singular place to place all your global or file data layouts and elements, procedures, and all.
With this in mind, I evaluate any dictionary type items in that manner; Windev does not allow a “Global” data definition, each item needs to be in the Project Code or somewhere to see it, so the only thing that is in the analysis is actual datafiles, this is disappointing. CW has only had this feature since (if I remember right) 4.5 or 5.0 , but it certainly helped putting all your global data area’s in the DCT.
It would be excellent to see where we could not only put file structures in the Analysis, but Structures as well, in several applications that use the same analysis, instead of having to recreate in each project, having it in the analysis to reference would be great. Also, allowing you to define arrays as well or Stored procedure calls.
Lets go over what it does have, I can import 19 different data storage types, you can also drag and drop a XML document into the analysis and it will define the XML into each element, really nice since you can now even show the data and information on windows from the xml with same coding that you currently use for any other data file.
MSSQL VIEWS: unless you have the native driver, you are unable to import a view into the analysis, but there is obviously a way around that. Create as a NEW File, specify the Name, and information then enter all of the fields and types you have for the view.. once your done with that right mouse click on the file, go to the file properties and change the “Name of the table in the External database” to be the actual view in the DB. solved, done..
Once that is set, accessing the view is the same as any file. You can also use the QUERIES to utilize views as well, just depends on how you wish to work from it.
The analysis pane is basically a LDM,(logical data model), you can have a CRM(conceptual data model) as well along with reverse engineer a UML model for the analysis, allow you to create CLass layouts for each datafile to be used in your development.
Stored Procedures, Stored Queries, Triggers
For all those that are SQL RDBMS developers, don’t be confused, Stored procedures/triggers are not references to the Backend calls of either, or definitions.
What these are is repositories for code that is executed based on Add/Change/Delete of a file in the analysis, on the client machine not the database, which I don’t recommend unless your not using a RDBMS database.
But, there may be some code, that you either assign a variable, calculate information to assign to a field, that you wish to do PRIOR to the ADD/CHANGE where this comes handy.
In MSSQL everything is done POST entry,(unless you use a INSTEAD OF Trigger) and if your in a older based database, or don’t have control over the database, any updates on a File can cause recursion in a trigger that allows the record to update multiple times.
Triggers here can solve it, creating a Trigger in the analysis that updates say a total field when the elements of Price/Qty is updated would occur before the actual add or change to the DB and you would have minimal impact on the record. You have to use the Stored Procedures in Conjunction with the Trigger, you Create a Procedure or set of procedures and the Triggers Execute the procedure based on actions called for; As an example, you can setup that ALL files get a date time stamp for modification and the userid is assigned to the field, then setup a trigger to execute this on any write or add of any table.
Quite Powerful to keep functionality global vs individual forms/screens. I know I will be exploring this in detail as I continue my learning curve.
Stored Queries
There are standard calls to the database for stored procedures, TableFunctions, and even Function calls in MSSQL , for reports a majority of the information is denormalized as well as calculated using Table Functions.
Stored Queries can give you some flexibility that you cannot find in CW Dictionary. You can use them to setup Table Functions in MSSQL, now you already have setup queries as a DBA for your developers, or you can also Use them to call Stored procedures or functions. I am still exploring these and would like to see some extended functionality as far as no correction and passing parameters on the hand coded queries.
Quite possibly I am missing how to do this , and will continue to research. Overall, the Analysis is useful as a repository for my information, I can get around some limitations it has, as far as Views and other items without a native driver, and the fact that XML files are completely intergrated is a definite plus. BUT, I also don’t use the Hyperfile (native format) for file information, so the majority of “business rules” and “RI” code is in the database for me; making the analysis less of a concern.
This has been the same method as far as CW was concerned, since I have been in SQL for years, the DCT was mainly setup as a repository to use the fields in the program instead.
Project Management Module
Damn, what the heck is this, Project Management , why would we need this for an individual programmer?
More more in this ever changing world we need to bring in talent that we may not have, as well as explore avenues of development in multiple enviroments, OS, and even languages, this makes project management mandatory.
I have done a search on “google” for project management software came up with the usual suspects, as well as some freebies, and low cost items, none of which integrate into your development.
Clarion Project Management
In clarion we use Fogbugs for our project management, Wiki articles and Balsamic Mockups for windows. These tools allows us to design windows, and enter incidents and features for the product. Fogbugs is an excellent web based tool, but can be a bit expensive for smaller shops. There is nothing built into the environment for CW to manage bugs, Features for new products, or Team Development.
………………….. NOTE
Let me preface the blog as to say I am fairly new and there are others that have more experience in the windev environment, so check the comments on the articles as others that are reading may have information that I haven’t learned as yet.
Project Management (Windev)
The project monitoring center has the ability to Run locally or be put on the web, we installed the “control center” to the web so we could share “project” with Collaborators (programmers,managers).
There is a lot to go over, (I will go over the ones that I currently use, a few that are interesting , and if I run across something that is useful will add it to a future blog). I am guilty as most developers to short circuit design and management, once I get an Idea, as most I run into development and allow the project to flow accordingly, this is not always the best method, but we also need to realize that even the most rigid projects has issues and will need adjustments as it moves along.
Going thru the menu’s I ran across the WBBAL Messaging; this allows you to enter messages to other developers in the project, nice, but also is only geared to Windev, the Item I do like is that it allows you to take a lasso snapshot of a screen to send to someone else, neat little feature.
Major features include:
- User Management (add /change /delete users and contributors).
- Requirements
- Create Teams
- Spools (Message / data areas).
User management has the usual items, adding a user of the Control center, setup rights for that person, assigning to projects.
Requirements: Probably the most important item, this is the list of requirements for the project, what it is supposed to do, accomplishments and the goals.
To me Requirements are generalizations, you can get into detail, but I reserve that for the Tasks for the requirements, so as a Requirement for a project like Materials Management the following may be appropriate:
- Customer Management
- Equipment Management
- Inventory Management
- AR
- Invoice Processing
- Employee Management
- Reporting
There are others that will be more detailed adding Items under it that is fine, use it to your specific needs.
I do like that it allows attachments and saves those for others to review, this allows you to have Screen designs, either from an existing software, balsamic designs, or online notes/emails that was recieved.
Once you have created a Requirement, Couple of Icons to the right is “enter a task for the requirement”; Cool part is the initial tasks entered,
- Completion of requirement
- Test Requirement
- documentation of requirement
These are defaulted when you choose the “multiple Creation of tasks” for customers we will add in the following items
- Allow ADD/Change/Delete of customer.
- insure delete of customers has no invoices/AR
- If customer has AR/Invoices and users wish to delete, mark as “Visible=No” and filter screen.
- Allow user to sort/filter on name, Address, Phone
- Master filter on Visible=True , allow user on screen with checkbox to “Show All”.
- Show on screen current open invoices.
- Show on Screen Current AR Status of amounts in 30/60/90/120>
You can set the type of task, estimated time, who is to do it, and deadline if needed. Dates are automatically created based on how much time you allocated and determines from other tasks assigned when your time is available.
The cool part is if your running multiple projects, it references times and items your working on elsewhere and determines dates and times accordingly. So if I get involved with several items, I can safely tell a customer or another developer when I will be ready to work on that portion of the project.
In today’s environment of developers spread around the world, such integrated Project and task management is invaluable, if you take the time to setup , you can easily let your customer or managers know your schedule, availability and what your working on .
You have on your Project Monitoring , a schedule calendar, task list (can filter by project), fixed tasks, recurring tasks, and even interrupting tasks. Each of these will adjust timelines as you complete/insert new tasks, you can move tasks up and down the list, to reorder and it will also change available date to match.
As you develop a small window appears that allows you to choose which project/requirement/task your working on and assigns time to it, it is quite intelligent as it will suspend or ask you if it determines that no work is being done for a specified period. This allows interruptions not to destroy your timeline or time associated because you forgot to turn it off (fogbugz problem).
Couple that will allowing your holiday schedule, this is a very robust system that integrates into your Project development, If your not using a “Project Manager” or in windev and not using the feature , it would be a good idea too start.
I am impressed that an integrated management system solves my major issues, over the years, I have seen or been involved in several project management systems, most issues have been:
- Too complicated to run easily
- no internet capability must be in-house only.
- web based, not enough features.
- didn’t intergrate multiple Projects.
- Expensive to run in time and cost.
- Not intergrated into the development environment.
It is refreshing to see a simplistic, realistic Project management system integrated into Windev, and I will be breaking old CW habits and start using it.
Next we will start the Project.
SCM – Source code Management / Project Tools
SCM – Source Code Management
This is something that frankly Clarion has been missing for years, there is some 3rd party tools you can use, but most all of them you have to go to the APP level to do good job, In order for Clarion to fully use a SCM it must use Export/Import DDE and get the TXA from the app instead.
At one time, there was an attempt at this, but the newsgroup had a plethora of problems posted , I am sure there are those that have it working as desired, finally, but the vast majority in my opinion has probably gone to 3rd party/app level as we have or given up.
Windev takes the SCM to a bit more level than most, there is a local version when you install, allows you to keep versions in a Hyperfile file (windevs proprietory) , but that kinda defeats the purpose. The best thing to do is install the SCM on an internet server, our friend Glenn Rathke provided this service for me at Soft Design Consulting as we work together often (another semi-Ex clarionite) .
Setup was fairly simple, you can setup users in the system and determine what projects they can access and not access. This allows security for multiple projects to be managed easily , both personal and collaborated projects. The best thing about this is now that it is internet based, it allows you to get or put items in and out of the SCM anywhere there is internet.
Speed; this is much better than I expected, I have been on Cable as well as DSL, and checkin/checkout both are better than expected and well within my patience level (minimal<G>). Additionally there is a “Mobile” option, this option allows you to seperate from the SCM when internet is not around, then later resync your changes back to the SCM.
One test I have not had the ability so far to test, is 2 different persons one on and one off changing the same procedure then see how the sync works (will be testing soon).
For those that think that SCM is not necessary, think again, anyone that has lost portions of a project, or hard drive crash and hadn’t backed up in a few days, will attest that backups/SCM and the capability to see versions to choose from is not an option , but is mandatory for proper development whether your a single developer or works with a group.
With todays “Team development” environment, the SCM that Windev provides is perfect, a lot of team members are scattered and can even be in different countries, ALL portions of the project is archived, icon’s, the analysis (like clarion DCT) , automated tests, all portions of the project. If you have been working on a project and add a new developer to the mix, all they have to do is one time check out from the SCM the project and they will have everything you do to continue.
As an example, back in early 2000′s I had a conversion project , to move a clarion program to MSSQL as a backend, this was a large project of 20+ app’s and it had to be done within a few weeks not months. I had written programs to read thru the TXA and find the areas and make some changes where needed, since this was a Time consuming effort and with the minimal amount of time to accomplish, I had 6 other developers contracted to assist; we managed to keep the apps in sync by manual means, but the effort took one person (me) 40% of my time to do nothing more than make sure apps where synced and capable of compiling.
If I had done this in windev, it would have been a no-brainer, all I would have to have done is add the developer and let them get a copy of the system and go to work.
Additionally Windev has 2 other tools, Project management, and incident management, the Project Manager is a fully concise management tool with abilities of multi project management, different developers, scheduling, task lists, and timelines.
If you take my blog where we had been defining the project, this is the place where all of those items are placed, questions are asked and answered here BEFORE your project starts , even if your the only developer. Project management allows you to manage the project and see if you are making a profit (time/money) or not, and refine your abilities to project completion. When over 80% of projects are not completed on time or money, maybe this should be mandatory <g>.. By also adding this to the internet server, it allows a remote project with developers worldwide even to be done, one of the main benefits of our new future in development.
If you haven’t been using the SCM I highly recommend it, and think that it should be mandatory for your development, I also highly recommend that you manage the projects using the Project Monitoring Center, as it will allow you to not only setup the entire project and let you know timelines, but modify if needed as you continue the development cycle.
I will go over the Project Monitoring Center / Incident Reporting in depth in another Blog, start looking it over, if you don’t have an internet server capable of remote management, contact me or Glenn, and maybe we can help.
Andy <<cowboy>> Stapleton
Components/DLL’s Windev
Built my First component in Windev, basically they are in essence the equivalent of DLL’s, or dot Net Modules in lower level languages.
What this gives you is some ability to break apart larger programs into functional areas, but it also adds a level of complexity to your development cycle; Here is what I mean.
When you start your design of any system, there are several ways to do this; I am going to give you a simpler method that has worked for me over the years. What I do is look at a project like a picture, my job is to break apart the picture into smaller workable sections, and within those sections each individual piece.
lets review our project using that method. We are looking for a program to manage our personal budget, with possibly going commercial with it. Lets break apart the sections.
- Database – we need to choose a Database / file storage.
- Main screen, type, how it works
- Budget categories.
- budget management section
- checkbook section
- bank file imports
- Budget / checkbook Reports
- Checkbook reconciliation
- budget reconciliation
- Asset management
- Debt management
that is the basics; in order to make this commercial , we need additional items;
- installation program
- Database upgrade system
- Incident/bug reporting
- distribution method
As we progress with the project over the blog entries, we will go over and further dissect the sections looking at both abilities in Windev , Clarion for Windows, and smattering of other languages. For today though, taking into consideration one of the items above, I looked into creating a Component to synchronize database schema, this solves upgrades to the database for the most part.
There is a couple things you need to do in order for this to work.
I use a remote database on hostexcellence.com , what I do is Create a Mirror Database that matches my work database, this is the master database that the component uses to sync any of the users database.
There are 2 scripts to run in the zip file, 2 table functions, and a table definition, run those in your master database and the installation as well; you send the connection information to the component and it will create tables/columns update procedures,triggers and functions automatically.
In order for it not to run everytime, i setup a customer record for each , with the version no in that record, comparing that version to your exe version of your executable will either run it or not depending on if the versions match. If you have questions I have setup a Skype public Chat for Windev - Andy_eafxtrader is my skype name contact me and I will be glad to add you.
Going over the development of the component we need to further section out the “Database Upgrade” Section;
- Connection information to remote and local
- check connection abort if failure.
- check all tables to see if exists
- check all columns within each table to see if they exists
- check all stored procedures for upgrade or creation.
- check all functions for upgrade / creation
- check all triggers for upgrade/ creation
- check all indexes for creation.
- Allow Manual Scripts to be run.
- Allow a Debugging system
Each of these has to be done in sequence, cannot check procedures before connection right? .. In Creating the component, I attempted to send a Structure, a Connection structure both to it, and was unable to do so, so only thing I could do was pass each item to the window, there probably is a better method, but remember I am new at windev <g> and will learn some other ways later. (maybe a more experienced windev person will post a comment on how)
In any DB there is set of tables / views that describe the schema of the database; this Information_catalog is what we use to determine changes. Any change in a function/Stored procedure or trigger will reflect the last changed date so yuo can use that to see if the current version on the computer is outdated and needs to be replaced.
So we created several procedures to accomplish our goal.
Main code — setup connnection
CheckTables — this reads the table names from the master, and “ValidateTable” checks the local table to see if it exists
CheckColumns — loops thru each column in the schema and “Validate Column” checks the local columns to see if exists
CheckObjects — Triggers/Stored Procedures and Functions are Objects in the Database, check each and validate Object
RunSqlSCripts — Check if any scripts are created to run for this version.
Windev has several types of access to the database, since we are using SQL we will use the hQueryWithoutCorrection, this allows whatever statement sent to be used, without windev attempting to change it.
One of the features that windev has is “code Blocks” this is a very useful feature as it allows me to take a generic set of code like a SQLStatement , Execute Query and store it. I have done this for quite a few things as anything I plan on using often ends up there.
Unlike clarion, Windev uses a Datasource to store the result set, Clarion (unless you use the dynamic driver) forces you to create a file buffer structure to retrieve the data, this buffer has to be authenticated in the Database as well, so over the years, you end up creating a Dummy result Table with different field types to get the results from a “ad-hoc” SQL statement.
It is refreshing not to have to do that again.
So we send the following code to check the Procedures as example.
In Clarion the above would be as such
LoadProcedures ROUTINE
Open(ResultTable)
IF Errorcode();Stop(ErrorCode()).
ResultTable{Prop:SQL}=’select SysID,TypeDesc,ProcName,sqlDefinition,ModifyDate From DBO.FetchSqlObjects()’
IF Errorcode(); Stop(FileError()).
LOOP
Next(REsultTable)
IF Errorcode() ; Break.
END
Both are not very difficult, other than having to create a structure in CW to handle the result set, there is quite a bit of similarity to the code. both are readable, both you can follow along.
Here is the difference in my opinion;
From here, you have to compile CW, get it in a program, move or insure source is available, to debug, open the debugger, SEARCH for the routine, then put a breakpoint in it. usually around 10 min to get to that point.
In Windev, I click the F9 Key, if there are parameters I fill in the values and your in the code your calling, elapsed time maybe 2 min.
The debugger in windev is quite robust, and light years ahead of clarion, it is more like VS debugger allowing you to see code, step thru it and display values in your variables. Although clarion can do this, it is quite a bit more difficult, especially in the OOP generated code. Kudo’s to windevs debugger, and something you should be quite familiar with.
This should give you something to start with, reviewing code styles of the two languages and ease of development.
Feel free to download and use in your programs click on the download page to retrieve it.
I will be writing the above as a DLL for Clarion for all my friends in the CW world as well .
Next Blog: SCM Source Code Management.
Andy <<Cowboy>> Stapleton

