All posts by admin

32 bit ODBC in the 64-bit Operating System

Note: This blog was written by Robert Ricketts, who is a Senior Support Representative at SoftVelocity. If you have any questions, you can post them here or even email us at support AT softvelocity DOT com

Now, on to the article! 🙂

There has been quite a bit of confusion about using the 32 ODBC Administrator and 32 Bit ODBC drivers in 64 bit Operating Systems so I thought I would put together some information to help when using 32 bit ODBC drivers, such as the TopSpeed ODBC driver.

For 64 bit Operating Systems, there is a 64 bit and a 32 bit ODBC Source
Administrator.  Both actually have the same name (odbcad32.exe).

You can launch the Admin applet from the command line (or a Shortcut) so you get the 32-bit version of the ODBC configuration tool. The command line is as follows:

%WINDIR%SysWOW64odbcad32.exe

Microsoft stores the 32 bit odbcad32.exe in the syswow64 directory and the 64 bit odbcad32.exe in the system32 directory.

N.B. If you just run odbcad32.exe, Windows will actually run the 64-bit version because the default system path has system32 ahead of syswow64.

From: http://support.microsoft.com/kb/942976

System DSNs are stored in the following registry subkey:
HKEY_LOCAL_MACHINESoftwareODBCODBC.INI

Registry redirection is enabled for this registry subkey. Therefore, system
DSNs for 32-bit drivers and for 64-bit drivers are separated. The 64-bit ODBC Administrator tool does not display the system DSNs that are created by the 32-bit ODBC Administrator tool or that use 32-bit drivers and visa versa.

User DSNs are stored in the following registry subkey:
HKEY_CURRENT_USERSoftwareODBCODBC.INI

Registry redirection is not enabled for this registry subkey. Therefore, both
ODBC Administrator tools display all user DSNs.

Regarding the DotNet Framework

In order to use the TPS ODBC driver from .NET you will need to use the .NET Framework Provider for ODBC.

If you see no reference to the .Net Framework Provider for ODBC, this is
available as a free download from:

http://www.microsoft.com/downloads

Search for “ODBC .Net Data Provider” to download and install the .Net Framework Provider for ODBC.

What’s new in Clarion 7.1?

As we are working hard to closing the next and greatest release of Clarion, I wanted to share with you my presentation at the 2009 Aussie DevCon and present to you a quick summary of features to look forward to in the days to come.

IDE

New Windows 7 manifest support, built into the application’s template support.

Expanded support and customization for the Command Line Interface Utility (ClarionCL). You can now build and run applications and convert dictionaries from outside the IDE.

The “Most Recent” list is now preserved even if the IDE crashes and if you have multiple copies of the IDE open, the Most Recent list will show the most recent from all copies of the IDE

You can specify dictionary (DCT) files are automatically imported and exported to text format. The Tools/Options/General/Binary File auto-export/import dialog allows you to configure this.

New Subversion support:
Subversion options can be accessed via the context (popup) menu for solution items

Subversion options can be accessed via the context menu for Clarion for Windows projects

Subversion features of the IDE will use the text representation of a dictionary rather than the actual dictionary (DCT) if the dictionary is registered to auto import/export.

Application Generator

Window and Report tab controls have been replaced by Buttons. Additional ellipsis buttons added to call the Window or Report Editor to view source.

If you press either the Window or Report buttons on the main application tree, you now return to the application tree when you have finished using the formatter.

New Save and Exit button added to Application Tree. This distinguishes the Save and Closing of the Application Generator from other dialogs.

New Application Option to control the size of the recovery file before an AutoSave occurs.

New and improved Window Preview option built into the Structure Designer, with advanced data configuration options!

You can now set the tab style that the Window Previewer will use via the Tools > Options > Clarion > Window Previewer panel.

New and improved Expression Editor interface!

You can now open multiple solutions that access the same dictionary in multiple instances of the IDE.

Class Browser

New option in Class Browser Settings that allows to show/hide entities from included files. Class Browser Settings is a dropdown button on the Class Browser toolbar, and the new option is located at the bottom of the dropdown menu. Objects from included files are hidden by default.

Database Browser

New toolbar button and right-click support to specify picture token, heading and justification.

Data/Tables Pad

Ability added to copy field definitions from source code and paste them into either the Data / Tables Pad or the Dictionary Editor. When copying and pasting the details of a field that has an initial value from the Dictionary Editor or the Data / Tables Pad, the definition now includes the default value where possible.

Data/Tables Pad now has Expand All/Contract All buttons.

When a group or queue has focus in the dictionary editor or data pad, you can now add a field to the start of the group/queue, to the end of the group/queue or after the group/queue using either the context menu, the INSERT key, or the drop down list on the add button on the toolbar.

Dictionary Editor

TopSpeed Driver String Builder dialog now includes support for the TopSpeed Enhanced Encryption Support driver strings.

Support for alternate field and blob names for SQL drivers for specific SELECT, UPDATE, and INSERT clauses.

The driver string builder for ODBC based drivers now allows you to set the ZERODATE switch to any date value.

Dictionary Synchronizer

Improved support for handling Microsoft SQL Server 2008 data types.

You can now set the ODBC Catalog and Schema when importing/synchronizing tables from an ODBC data source.

Language Changes

New PROP:TextLeftMargin and PROP:TextRightMargin properties for ENTRY, SPIN, COMBO, TEXT, RTF controls and for drop-down list-boxes

PROP:LastChanceHook SYSTEM property.

SETEXITCODE and GETEXITCODE built-in functions to set/query program’s exit code (error level) without the necessity to immediately close the program.

New MSGMODE:FIXEDFONT flag in the last parameter of the MESSAGE function to show message text using the fixed-pitch font

Two new built-in functions FREEZE/UNFREEZE with the purpose of reducing flicker in some situations.

New conditional operator support added to the OMIT and COMPILE directives.

New PROPLIST equate (LISTZONE:GroupHeader) used to determine if the mouse is clicked or moved inside the list box header, but outside of the field part of the header. This change has been used to provide better highlighting of themed list box headers.

 

Template Language

New support for pre and post build events using the #PROJECT statement

New PASCAL attribute for the #RUNDLL statement. The WIN32 attribute is now deprecated and ignored.
More to come this week!

Aussie DevCon 2009 Wrap-Up

Aussie DevCon 2009 Wrap-Up

Well, it’s been a little over a week since I’ve back from the land Down Under. I think that the jet lag is finally over, and I wanted to share with all of you some thoughts about the conference.

First and foremost, I was to thank Jen and Geoff Spillane, Margaret and Ken Wragg, Maury, and all of the other Eden locals who once again truly manifest what the word HOSPITALITY really means.

Thanks to my colleague Pierre Tremblay, who endured the long plane ride over, fought off the flu that was circulating among some of the attendees, and delivered some interesting and useful training that targeted the Clarion.NET product.

Thanks also to Robert Zaunere, who also endured one of the worst flights ever (I’ll let him tell you) and delivered a marvelous demonstration of the Clarion.NET application generator and all things LINQ.

The attendees were treated to an early release of Clarion 7.1 – this was the build that I was using all week in the training. It’s intent was to reinforce the training and allowed them to get a first hand look at many of the new features of Clarion 7.1. Since that time we have added even more fixes and features, and with a little more testing left to do we hope to have it in all of your hands very soon.

It looks like I have a lot of documentation ahead of me, as Bob Zaunere introduced the LINQ to FILE provider and the many new methods behind them. You can read more on this in another blog on this site. That’s just the tip of the iceberg, there is a lot more to come!

Yes, we did see some whales up close and personal at the Whale Watching cruise. One whale came right up to the boat and circled it 4 times as he was as curious about us as we were of him. It was amazing to see such a gentle but huge creature in the wild. It was definitely worth the trip.

On the way back to the states, we stopped for one night in Sydney, and yes, I found a ten pin bowling center in Darling Harbour. The score wasn’t great, but just the act of being there was very special.

If you missed the conference, you missed a good one, but the guys at Clarion Live did a great job of keeping the rest of the world connected, and plans are in the works to make the conference available on DVD very soon.

Looking down the road, we hope to have our next US Developer’s Conference in 2010 soon after the Clarion.NET Gold release. Probably in Orlando in the second quarter if everything moves ahead as planned. It’s long overdue and something that we are all looking forward to doing.

A Whale of a Time!

I woke up this morning and suddenly realized that in two weeks I will be flying back to Eden in New South Wales for the 2009 Aussie Devcon!

I can’t wait to get back there and feel honored to showing you what we’ve been cooking over the last few months.

If you haven’t booked your seat at the conference yet, please visit the Aussie DevCon web site and reserve your place, as the time is fast approaching.  Here is the link to get started:

http://clarion.net.au/

You’ve got to be there! The progress and maturity of both Clarion 7 and the Clarion.NET products have been significant and dramatic in many areas since last year’s Aussie DevCon. Last year, Clarion 7 was in beta, and the Application Generator was still in its early stages. Today, we are just around the corner for Clarion 7.1, and the Application Generator is better than it’s ever been, including our past versions. I will be using Clarion 7.1 exclusively during the training and conference, and we hope that all of you will have it by then as well.

The training this year is titled “Exceptional Development Techniques in Clarion 7 and Clarion.NET”

With the many months of working with Clarion 7, I will be covering many topics that have been of major interest to our developers. One of the topics will be an in-depth look at the C7 Project System and leveraging it for maximum productivity for your single and multi-application projects.

Of course, I will be highlighting Version 7.1, and all of the new features and changes in it. We will be exploring the heart of application development with an in depth look at the Dictionary Editor and Application Generator, and explore development techniques and solutions via the template and embeds that you may have missed.

I will also be giving you a first look at the new ReportWriter, and hopefully you will see why I am so excited about this new addition to Clarion 7 and Clarion.NET.

Many of you have an interest in the triumverat of add-on products for Clarion 7, the In-Memory, Dynamic File, and Internet Protocol drivers, and we will devote a section of training to using these products in your development solutions.

I could go on, but see the full training and conference schedule for yourself at the following link:

http://clarion.net.au/index.php?option=com_content&task=view&id=33&Itemid=35

My colleague, Pierre Tremblay, will also be a presenter at the conference and training. Pierre has been using Clarion for almost as many years as I have, and his experience with .NET development has given him a powerful perspective and vision in presenting the latest Clarion.NET IDE.

 

Here are some comments from Pierre, and what he has planned for the conference and training.

Aussie Devcon 2009 is a real excitement for me! I have the privilege of presenting Clarion.NET WinForm and WebForm related topics during the conference and training.

Here are highlights of what we will discuss.

Regarding Clarion.NET and Winforms, we will talk about what is a WinForm application and look at the most popular controls used to build the user interface.  We will also talk about the Clarion.NET language and explore events, delegates, interfaces and look at examples using them. We tend to associate events with a user interface, but events in Clarion.NET are a different paradigm, and we will examine an example of that.

Speaking of user interfaces, we will also discover the benefits of using a UserControl in a WinForm application.

We will also discuss data binding. When you hear “data binding”, we often associate “data” with “database”, but you will see that data in data binding is different and much more generic.

We will look at the building blocks of ADO.NET. This includes a look at Datasets, DataTables and the role of the DataTableAdapter.

On the ASP.NET side of my presentation and training, we will first get in touch with AJAX. We will understand why most new projects involving ASP.NET those days involves AJAX. AJAX is so popular that it is now a built-in assembly in the 3.5 .NET  Framework.

We will explore ASP.NET master and content pages to see how we can develop a standard look and feel in our web applications.

We will also examine WebServices, how to create them and how to consume them.

Finally, there is a segment showing how to incorporate a 3rd party control library in the IDE. We will explore the steps to achieve that and we will also look at how we can create a QuickStart template that automatically includes the new library.

Our CEO, Robert Zaunere, will also be back for this year’s conference. Robert has some very exciting news and information to present at the conference. At the forefront is the first look at the Code Generation model for Clarion.NET. He will explain the architecture of the new templates, as well as demonstrate the application generation process. Another topic that he will be presenting is the new Clarion support for LINQ (Language-Integrated Queries).

***********************************

If that’s not enough, some of you might wonder why the conference was scheduled in October this year instead of the previous May. The answer is that the conference is being held right in the middle of Whale Watching season. Geoff Spillane has organized a very special Whale Watching Cruise for the morning of Friday 16th October. For those who attend both Training and Convention (the full 7 days) they will qualify for participation in the cruise for free. How cool is that?

***********************************

So hpefully now you know why Pierre and I are excited about Aussie DevCon 2009. Come and see what a great product Clarion 7 and Clarion.NET really is, and even greater are some of the developers that will be there. I am looking forward to meeting some of you for the first time, and for the warm reunion ahead for those of you that I met last year.

We hope to see all of you there!

4th of July Weekend

I just wanted to mention that our home office will be closed on Friday, July 3rd in honor of Independence Day. To all of you, have a safe and relaxing Holiday weekend and we will be back in the office on Monday, July 6th. Thank You!

My Success with Clarion 7

When I look at the big picture of my life, I guess I have always been a consistent person, living in the same house since 1985, married to my wife for 22 years this October, and bowling every Friday night in a mixed league. Also important, this November marks my 20 year employment anniversary with the Clarion home office. Sounds boring to some, but all of it seems like a blink of the eye to me.

So why am I mentioning all of this? Clarion 7 is a major upgrade, and now I had a requirement to upgrade one of my favorite real world applications, my Bowling League Manager.

There has been a lot of chatter on the newsgroups regarding problems upgrading applications from C6. I can tell you that “my” producation application is critical to me, because bad bowling statistics can cause discrepancies in standings and individual awards which can cause incorrect league money to be awarded. Many times the bowling center has made mistakes that my audit trail was able to correct, so this program is very important to me.

I had a situation last weekend where my bowling league management application needed a major change for a summer league I am running, and I am very happy to report to you that the conversion of my application from Clarion 6 to Clarion 7, dictionary changes, table conversion, appplication window changes, and finally changes in important hand coded processes was smooth and quick and very gratifying. This blog summarizes what I needed to do and how I did it.

To torture myself this summer, I accepted an opportunity to manage and run a Sport Bowling League called the PBA Experience (the “torture” is the tough sport bowling patterns). As an incentive to recruit new bowlers, the bowling center had given us four games for the price of three.

Now in my 20 plus years of bowling I have always bowled a 3-game series, so it was time to make a change to the league management software.

My first step was to convert the Clarion 6 application and dictionary to Clarion 7. No issues to report here, the conversion was smooth and easy.

11 table dictionary, but nearly all tables related. There are Bowlers and Bowler Master and Bowler Weekly tables, and the same thing for Teams. Add the Schedule and Weeks and Divisions and that’s the core of the database.

Step 1: Add a Game 4 to the Bowler and Team weekly tables. I used the Dictionary Copy and Paste, copied Game 3, and then renamed the result to Game 4.

dctstep1

Step 2: Convert the existing tables to their new format. I took the easy route and let the dictionary auto-convert my bowler and team weekly tables, creating a backup of my test data. I was very happy with the results:

dctstep2b

dctstep2c

That’s all I needed to do in the dictionary. The next stop was the Application Editor. Again, it’s a typical application with roughly 50 procedures. Lots of reports and 3 key processes.

Step 3: In the Application Generator, I needed to add the new Game 4 fields to two forms, the bowlers and teams weekly updates:

appdesigner1

I quickly got the hang of the alignment toolbar, and decide to use the Populate option in the Menu instead of the Data/Tables Pad. Again, just a creature of habit!

..and finally, my process logic in several embed points now needed to account for the additional game:

appdesignerembeds

I really like the new embed editor, with code completion, quick class browser and all of the other features. In most cases I simply needed to add the Game 4 logic where needed. A lot of it was copy and paste. I won’t bore you with all of the places I changed. I will say that in this case the Data/Tables Pad came in VERY handy, as I was able to easily drag and drop the field names that I needed into the embeds.

I wanted to test this quickly since the league was starting in a few days. Looking back, I will add conditional logic to the league configuration file to set it for 3 or 4 games, and then wrap my logic around that condition.

The rest of the story was non-eventful…Generate, Build, and Run. The program works perfectly, and in the next couple of days I will add the Game 4 column to a few end of season reports.

Here are the procedures that I modified, all in total about 1 hour’s work.

summary

In summary, working with Clarion 7 was extremely satifying. I know that there will be other projects that will be more challenging in the months to come.  As the project progresses I know there is more work ahead, but I am looking forward to it.

Easing into Clarion 7 – Part 9 of 9 – Application Options

In Clarion 6, your options for different sections of the IDE are located in an IDE Setup Menu:

c6setup

In Clarion 7, all of the important Application, Dictionary and other important IDE options are all accessible from the IDE Tools Menu:

toolsmenu1 

There are three new Application Options of note:

On the Application tab:

Check the Auto-Make Applications before compile box to trigger the Application Generator to generate source prior to the Build action if needed.

Check the Auto start designer on pressing the Window or Report button box to auto-load the target Designer when pressing the Window or Report button located on the Procedure Properties window. You can still view the Window or Report text by pressing the tabs in the Procedure Properties window.

On the Generation tab:

Check the Use long file names for generated files to generate application source files using the full application name followed by a three digit module number.  If you would like to use the older 8.2 naming format, clear this box.

blueline

The Dictionary Editor also has some great new options to help you fine tune your development environment.

Set the Initial Version Text to display the text to display when the version is set. When you first create a dictionary it has an initial version with a name equal to what you set in that field.

During the lifetime of the dictionary you can create new versions.
Each version is a marker that is used in the Audit details of an object. If you go to the Audit tab of any object in the dictionary you will see a Version against the Created and Modified details. This indicates which version of the dictionary the object was created in and in with version it was last changed.

The Initial Freeze State defines the initial “Freeze State” of the dictionary components as they are first imported.

After a conversion program is generated the Load Conversion Project option sets how you can load the project. You can set this to always load the project, never load the project or ask each time a conversion program is generated. The default is to ask.

When Enforce Clarion# name restrictions is checked, the dictionary editor will not allow you to create labels that are not valid in Clarion#. For example. AS is an illegal label, but legal in Clarion for Windows. If you do not want to worry about Clarion# restrictions you can uncheck this box.

If Clarion# restrictions are enabled and you load a dictionary into the editor that has a label that violates the Clarion# naming restrictions the editor will automatically rename the object to ObjectType_OldLabel, where ObjectType is a Table, Alias, Global, Pool, Key or Column. If the object is a Key or a Column with no external name, the external name is set to the old label.

For example, “AS STRING(10)” will be converted to:

“Column_AS STRING(10),NAME(‘AS’)

Any such change will appear in the Dictionary Changes pad.

 

Easing into Clarion 7 – Part 8 of 9 – Where’s my Property Editor?

In the Clarion 6 Window and Report Formatters, there is a special Property Editor (F12 Key) utility where properties of multiple controls could be viewed and modified:

c6propeditor 

In Clarion 7, the Property Editor is no longer needed, and has been replaced by the new Properties Pad:

 propertypad

Open this pad in the IDE at any time by pressing the F4 Key. The properties that you will view are based on what IDE element is currently selected. Usually this is a WINDOW, REPORT, or a control, but it could also be one of many project elements.

The new Property Pad is easier to use, displays more information in one view, and is more flexible. You can sort alphabetically or by category. To update properties common to multiple controls, simply lasso or select the target controls in the Designer and change all properties as needed.

proppad2 

 

Many property values are comprised of a finite set of choices (i.e., colors), or sometimes just a “TRUE” or “FALSE” value. Use your mouse or cursor keys to navigate to a target property value, and then click or press the space bar to cycle through valid choices.

 

Easing into Clarion 7 – Part 7 of 9 – Lazy Loaded Applications

With the ability to maintain multiple applications within a single solution, there are common shared elements of the applications that can be pre-processed prior to editing and source generation. This pre-processing of a
selected application is called lazy loading.

In the Clarion 7 IDE, a fully opened application is one that is loaded in the Application Editor.  However, applications can also be “lazy loaded”, meaning that the application may not be loaded in the Application Editor yet,  but the application template registry and any parsing of source libraries required by the templates has been performed. This allows for faster loading of applications into the Application Editor, and allows the project system to more efficiently build applications that are not currently opened in the Application Editor.

“Lazy opened” applications in the Applications Pad are marked with a special icon (highlighted in yellow below):

 

apppad

 

 

Applications not opened or “lazy loaded” are marked with a different icon (shown above not highlighted).

The Applications Pad is a powerful tool in the Clarion 7 IDE. For solutions with multiple applications, you can easily select and generate the application that you need.

If you select an application to generate, and the application is not already opened, the Generate action will “lazy load” the application as described above.

 

Easing into Clarion 7 – Part 6 of 9 – Maintaining a Multi-Application Development Solution

One of the fantastic new features of the Clarion 7 IDE is its ability to manage multiple applications in a single solution. I mentioned this in my very first blog in this series. (See Part One in this series if you haven’t already done so). 

Every development project is contained within a solution. Of course, you can have a single project associated with a single solution, and for most of the time, this will be the case.

However, a solution can also contain multiple projects. As always in Clarion, projects can be hand coded (source only) or, they can be associated with an application file, where templates and embeds are responsible for generating the project source.

Since multiple projects can be contained in a single solution, it is also true that multiple applications can also be contained in a single solution.

And yes, for your projects where multiple applications were needed (some produced DLLs and one produced the executable), they can now be managed and maintained in a single solution, and you may edit them all at the same time!

For example:

 multiappdisplay

How cool is that?

And this brings me to the main point of this particular blog. An application is always a part of a solution, but since solutions can contain multiple applications, you must be aware that closing an application does not automatically close a solution.

So, the Save and Close button shown here:

saveandcloseapp1

…will only close the active application (e.g., “Allfiles.APP”)

To close an entire solution, first close each application opened for editing, and then use the Close Solution button in the main IDE toolbar (shown here).

closesolution 

As shown above, you can also use the CTRL + SHIFT + F4 hot key combination (or use the File > Close > Solution IDE Menu item).

And rest easy fellow developer, you can only have one solution active at any time in the IDE, but with the ability to launch multiple sessions of the C7 IDE, well, that’s a topic for another time! <g>