
Free White Paper reveals new software training model:
Perfect Coaching - How Companies
Are Maximizing Software Delivery ROI through Just-In-Time-Training -
Download a
copy
For more information on Perfect Coaching, contact Visionpace at
coaching@visionpace.com
or call 816-350-7900 or 888-904-7900 and ask to speak with someone
about Perfect Coaching.
June 29, 2009
Are Ya Catchin' This, Camera Guy?
Hear that sound? Tick-tock, tick-tock...
That's the countdown clock at the main office of Geek Gatherings and it is getting closer to the super-saver deadline for the 2009 Southwest Fox Conference! July 1st is just a couple of days away and I thought I would pass along a reminder just in case you forgot to type it into your task list or stick it on your monitor on a yellow sticky note.
The Southwest Fox Stimulus Package holds firm on the cost of registration if you register by July 1st. Yes, registration will be the same cost as last year’s conference IF, repeat, IF you take advantage of the new "super-saver registration" deadline. Can you say JULY FIRST, boys and girls?
Southwest Fox 2009 will take place in Mesa, Arizona USA and I strongly suggest, if you are still developing in Visual FoxPro, that you think long and hard about being there. Don’t miss out on the $125 discount, the free pre-conference session, and a chance at the $300 scholarship from White Light Computing.
Already registered? Great! Spread the word (hey, that is what I am doing right now) among your fellow VFP developers (who have been procrastinating) that the deadline is looming nigh?
Read about the registration process and get the registration application here:
http://www.swfox.net/register.aspx
OK, that sounded kind of bland, but now I would like to add the emotional/excitement factor. The first half of this blog was the facts, ma’am, just the facts. This second half contains (although not in its entirety) stuff that I am looking forward to doing and experiencing at the conference.
Reviewing and reinforcing all I can about the VFP9 Report Writer and ReportListener. Show of hands, please. Who, among you, has still not explored all of the capabilities of the ReportListener? i h v my h n up in h ir. This is the PERFECT opportunity to do just that.
VFPX – Lots of us have heard about it and maybe even played with it a little bit, but THIS TIME at THIS CONFERENCE, I vow to pick the brains of EVERY speaker who is presenting ANYTHING concerning EXTENDING VFP. It will look like a scene from “Hanibal” (Silence of the Lambs – Part II). Doug Hennig (GDIPlusX), Jody Meyer (Extending the VFP Grid Object), Jim Nelson (FoxCharts), Rick Schummer (Enhancing the VFP IDE using VFPX Tools) all better look out. I wonder which goes best with a nice Chianti? Learn to extend VFP to make it bigger, better, richer, fuller!!! I am ready. How about you?
Christof Wollenhaupt has a session about “Excelporting”. That’s just a fancy word that means “make your data look like a spreadsheet”. Sounds like something I need because my clients are always asking for DATA in a SPREADSHEET (and not just using the COPY TO command).
Those are just some of the session that I plan on attending. Your mileage may vary, but if you go to http://www.swfox.net, you will be able to see the entire list of speakers and a brief description of the sessions. Don’t delay; you just have a couple of days! Hope to see you there (unless you are an obnoxious “know-it-all”, in which case, I will just mosey on over to the bar and order another adult beverage).
Posted by Dave Aring on June 29, 2009 | Permalink | Comments (2) | TrackBack (0)
June 24, 2009
A Joke Isn't Old If You Haven't Heard It Before
The weather here in Kansas City is going to be very warm today. The prediction is 97 degrees and with the humidity, the heat index will make it feel like it is 110 or more. This allows me to tell my annual “how hot is it?” joke. How hot is it? Coming back to the office today, from lunch, I saw a dog chasing a cat across the parking lot <pause> They were both walking. <insert rim shot here>. Now, some of you laughed and some of you groaned and some of you said, “Geesch, that joke is so old, I heard it when I was in the third grade.” I would counter and say that a joke is not old if you haven’t heard it before.
I learned something “new” yesterday that I know is not new, and in fact, might be known by tons of Widows users. However, since I didn’t know it, perhaps you don’t either and that is why I am passing along this bit of “new” information. I have encountered this situation many times throughout my career, been annoyed by it, and yet, never knew I could do anything about reducing my frustration. Yesterday, I was at a client site and the location of some text files I wished to access was stored somewhere on their server. The folder I wanted to access was about six levels down from the root directory and each level had a minimum of 50 folders. Needless to say, migrating to the desired location using Windows Explorer was tedious. Not very tedious the first couple of times, but since I had to do this about every five minutes, it quickly became very annoying. You know the drill (no pun intended)… Open up Windows explorer, search the list of folders for the first level, click on the folder, locate the next level from among 50 folders, find it, click it, and so forth until you have navigated your way to the final level.
It was when I mumbled something about how frustrating it was having to navigate all the way down to Dante’s seventh level of hell, that my contact at the client site stopped me and showed me his technique. Since I think this is such a cool trick, I have to give credit to Patrick Hansen of Penton Media who showed it too me. I hope I am not blowing it out of proportion, but this is one of those tips that I will use often and now, maybe you will too. Navigate to the desired folder in Windows Explorer. Once there, you can add that “location” to you list of favorites at the top of the screen just like you would do for one of your frequently visited websites. Yep, that’s right. Just click on Favorites|Add to Favorites… and enter a description. The next time you need to get to that folder, just open Windows Explorer, click on Favorites and it will be there. Click on the link and you are immediately transported to the desired location. I think this is the closest I will ever get to “Beam me up, Scotty”.
Now, all of these shortcuts to various folders will show up in your list of favorites when you open up Internet Explorer also. Because of this, I created a new folder in my favorites named “Explorer Folders” and the name of each link is the full path I want to go to. Each level is separated with an underscore for clarity. i.e. G_Departments_BookGroup_MarketingRep_Extracts_Colorado_Aug08. What a time saver! Thanks again, Patrick. You CAN teach an old dog new tricks.
Posted by Dave Aring on June 24, 2009 | Permalink | Comments (4) | TrackBack (0)
May 22, 2009
It may not be a big deal to you, but it is to me.
A Visual FoxPro User Group buddy of mine, Larry Koska, contacted me recently and asked me to confirm his suspicions. I immediately told him, "I agree, you ARE ugly." While this may be true (he's gonna squash me like a bug the next time he sees me), it wasn't what he wanted to confirm.
It seems that tool tips for objects in a grid that have been previously working flawlessly are no longer visible. Would I run his form and see if I got the same results? Sure, but, all knowingly, I reminded him that I shouldn't have to "waste" my time because (undoubtedly) what had happened was that the ShowTips property of the form on which the grid resides probably got accidentally reset to .F..
"No, dummy, (Larry and I clearly have a mutual admiration society going on), I am not that stupid. That was the first thing I checked."
My response then was, "Lar, this may actually be a problem. Let me check it out."
And so the mini test began. I fired up his form and everything worked as expected. I could see tool tips specific to the grid, to the columns, and even the column headings. And yet, I had to believe that Larry knew what he was talking about; he usually does. So, why would the form work on my machine and not his? What recent changes might he have made? A quick phone call determined the difference. Both of us are running VFP9, both of us have access to Vista OS and XP OS and tested on both OSs. The only apparent difference is HE (always on the bleeding edge of technology) is running Service Pack TWO and I (invaribly on the coaggulating edge) am running Service Pack ONE. To confirm, he reinstalled using SP1 and the exact same form work as expected. Mystery solved. Now I am going back and review a recent blog by Rick Schummer (April 8, 2009) to make sure this bug gets reported properly.
Getting tool tips to display may not seem that big of a deal, but if I didn't want them to be displayed, I wouldn't have gone to the bother of creating them. I am glad to see that Larry, as a developer, followed through rather than re-evaluate the need for tool tips. Besides, as quite often happens, I learned something and because I worked on it, I will remember this issue. Subsequently, a Google search did discover a discussion of this issue and that MIGHT have saved us time, but in the long run, I believe it was more beneficial to have gone through the discovery process ourselves. Afterall, it is all a big game and isn't that what we developers like best?
Posted by Dave Aring on May 22, 2009 | Permalink | Comments (1) | TrackBack (0)
April 02, 2009
One of the Reasons Why I Like Blogs
Blogs are something I can (usually) take or leave alone. Some are good and some are bad. I am aware of the reasons WHY blogs are (supposedly) important to businesses, but, at times, I question some of those reasons. It is difficult, although not impossible, to ascertain accurate numbers regarding how much new business, increased prestige, and other worthwhile benefits are gained as a result of routine blogging. One thing that is easy to measure, however, is how useful a particular blog is to ME. How a blog benefits ME is really the best reason that I can come up with to justify reading blogs.
Today's perfect example is the most recent post ( http://doughennig.blogspot.com ) by one of the legendary (hope that description doesn't go to his head) super-players in the world of Visual FoxPro, Doug Hennig. Hidden within the code that Doug generously provides is a Visual FoxPro function that I did not know even existed. The ObjToClient() function has limited use, but like most functions, when you need it, you are glad it is around. I have never used it, but after reading about it, I KNOW that I could have used it in the past when I "jumped through hoops" to achieve the desired effect. AND... I KNOW that I will use it in the future when the need arises.
I would not have gained this knowledge had I not been in the habit of reading Doug's blog. Now it so happens that, today, Doug's blog was the one that contained the nugget that made me a smarter software developer, but it just as easily could have been one of the many other blogs that I read on a regular basis. So, if you are not reading blogs regularly (which begs the question, what are you doing here right now?), get in the habit of spending a few minutes each day. I guarantee that, in the long run, it will pay YOU dividends.
Posted by Dave Aring on April 2, 2009 | Permalink | Comments (5) | TrackBack (0)
October 17, 2008
Phoenix in the fall; Arizona in the autumn
If you aren't at Southwest Fox 2008 in Mesa, AZ (http://www.swfox.net/) this weekend, you're missing a real treat. Tamar Granor, Doug Hennig and Rick Schummer have once again done an excellent job organizing a conference that is a tremendous value for your money.
To give you taste, here are some of the sessions I attended today:
- In "Profiling and Refactoring: How to Analyze and Clean up Your Code", Andrew Ross MacNeill talked about a powerful tool in VFPX called Code Analyst that can help you identify "issues" in your code (e.g., too many lines of code in a single routine, too many comments, too many loop structures, has more than one return value, etc.). (VFPX is a Visual FoxPro Community effort to create open source add-ons for Visual FoxPro 9.0). You can select which rules you want run against your code; you can also create your own rules.
You can download Code Analyst for free from the VFPX CodePlex web site: http://www.codeplex.com/VFPX.
Andrew also discussed an add-in for the Coverage Profiler.
- Christof Wollenhaupt gave an introduction to mobile development; employing his product, Guineu (Catalan for "Fox"), you can develop mobile applications from within Visual FoxPro. Cool!
- Doug Hennig talked about Advantage Database Server for VFP Developers; with this alternate back-end, you can either read VFP .DBF files directly or you can move your data into the proprietary ADD format. With Advantage Database Server (ADS), your .DBF files are no longer limited to 2 GB. "In ADS, there isn't a direct limit on the size of the file; instead, the limit is a maximum of 2 billion (2,147,483,648) records. Of course, if your DBF becomes larger than 2 GB, you'll only be able to access it through ADS since VFP will see it as invalid."
"ADS [also] has a fast and powerful full text search (FTS) feature. FTS uses an index on each word in a memo field to provide fast, index-based lookups for desired words."
- Rick Schummer did a presentation focusing exclusively on "Using VFPX Components"; he demo-ed various controls like Themed Controls (e.g., OutlookNavBar), the ctl32 project (e.g., StatusBar and BalloonTips [tooltips on steroids]) and Desktop Alerts. VFPX controls add pizzazz to your VFP applications, giving them a more polished/professional appearance. You can download these controls for free from the VFPX CodePlex web site (http://www.codeplex.com/VFPX) and then implement all of these controls in your VFP applications
- In "Creating Owner Drawn Controls in VFP", Christof Wollenhaupt showed us how to "exploit the power of GDI+ to create our own controls" in VFP forms (e.g., "new pageframes, progress bars, formatted text, chart controls, basic text input or Unicode text output"). He also covered "dealing with mouse and keyboard input."
- Bo Durban showed us how to create custom report controls with VFP 9, employing the GDIPlusX library; rotated text, dynamic text formatting, graphs and custom shapes are a few examples of things you can do/include in your reports.
I continue to see the common thread/theme of EXTENSIBILITY with respect to Visual FoxPro (that was also displayed in a 2-day West-Wind Web Connection training I attended on Tuesday and Wednesay this week [Rick Strahl's product enables you to create web applications using VFP and some other technologies like CSS, JavaScript, JQuery, etc.]).
Posted by abergquist on October 17, 2008 | Permalink | Comments (3) | TrackBack (0)
October 07, 2008
Bitten by Performance Counter issues in Virtual Machine
I've been using virtual machines for software development for just over 3 years now. At this point, virtually all of my software development is done on virtual machines (no pun intended... it was just a side effect).
About 8 months ago, I started noticing a recurring issue on my virtual machines with regards to SQL Server 2005. I was regularly getting errors in the application event log about SQL Server 2005 performance counters. Since this was the only error I was getting, and SQL Server 2005 seemed to plug right along just fine despite these errors, I ignored them.
Fast forward 8 months to today. I've been using SQL Server 2008 in development projects for a few months now. I had one particular virtual machine that did not have SQL Server 2008 reporting services installed and I wanted to install it today. When I ran the installation wizard, it kept failing during initial check steps, reporting that there was a problem with the performance counters. In this case, it would not let me install reporting services withough resolving this issue. The details reccomended following the steps of Microsoft KB article 300956, "How to manually rebuild Performance Counter Library values".
I followed all of the steps of this KB article (not a quick task mind you), rebooted and started the installation again. Much to my chagrin, it failed due to the same performance counter check failing AGAIN..... UGH!
Some additional googling let me to this blog post.
The short story here is that performance counters were disabled.... ALL OF THEM. Rebuilding them was a completely unnecessary step. I also know why they were disabled, and I will remember this for a LONG time to come.
I've been using VMOptimizer from Vizioncore (desktop version now discontinued) since before it was purchased by Vizioncore from Invirtus (or they merged, or whatever happend). There is a checkbox in the opimization options regarding disabling disk performance counters. Unfortunately, this is mislabled. It doesn't disable "disk performance counters", it simply turns off ALL OF THEM.
Guess when I started using VMOptimizer again.... say... about 8 months ago.
If you need any performance counters turned on, don't check this option or possibly suffer the same fate that I did.
JE
Posted by Jim Erwin on October 7, 2008 | Permalink | Comments (2) | TrackBack (0)
September 25, 2008
Dump unnecessary leading equals signs ("=")
You will often see a leading equals sign ("=") in older VFP code (especially in code ported over from FoxPro 2.x). A leading equals sign is necessary only in a couple of instances in VFP:
- when calling the SEEK() function and not storing the return value, e.g.,
USE (HOME(2) + 'Data\Customer') IN 0
=SEEK('Great Lakes Food Market', 'Customer', 'Company')
- when denoting an expression in a property in the Properties Sheet/Window; for example, when setting the .Caption property of _Screen:
='My Application (Version # ' + m.gcVersionNo + ')'
Side note, when setting the .Picture property for an Image control, include the equals sign as follows:
='MySplash.JPG'
If you specify MySplash.JPG without the equals sign and character delimiters, VFP will attempt to insert the path in front of the picture's file name; the problem is that that path may not (in fact, most likely will not) be on your customer's PC (when your application is production).
Posted by abergquist on September 25, 2008 | Permalink | Comments (0) | TrackBack (0)
September 19, 2008
It is not too late...
With less than a month before it begins, the Southwest Fox 2008 conference is set to start October 16th. It is the premier conference for Visual FoxPro developers in the nation and with over (an estimated) 100,000 VFP developers world-wide, Visual FoxPro will be around for a long, long time. The conference is the PERFECT opportunity to hone your skills and pick up new techniques to enhance future developments. If you haven't registered, IT IS NOT TOO LATE to register.
Having said that, it gives me the opportunity for some self-promotion. When you go to the conference website, look for the link to download the K.O.K.O.P.E.L.L.I. software written by moi. It will give you two hours of your life back. How? Well, instead of spending two hours trying to figure out the optimum schedule to ensure you see the sessions you are most interested in, the software prepares a "suggested" schedule based on your preferences in just a couple of minutes. Give it a try. If you have any problems, let me know by leaving a comment and I promise I will get back to you.
Hope to see all of you in Mesa, AZ in October.
Posted by Dave Aring on September 19, 2008 | Permalink | Comments (0) | TrackBack (0)
September 11, 2008
Character (string, text) delimiters
Here's my order of preference for character delimiters:
a) Apostrophe (') ... saves time since it is just one character and does not require you to press and hold down the <Shift> key ... easiest to read (least 'cluttered')
b) Square brackets ( [ and ] ) ... requires two (2) different characters but still does not require you to press and hold down the <Shift> key ... easy to read
c) Double quotes (") ... just one character but requires you to press and hold down the <Shift> key ... "busiest" in that it adds "white noise" to your code
I switch to square brackets if there's an apostrophe within the string. If the string contains (i) an apostrophe as well as (ii) one or both of the square brackets, then I employ double quotes.
Examples:
* My ideal is to employ apostrophes for delimiting character strings
WITH ThisForm
.icTableItemExpression = 'ALLTRIM(' + .icMainAlias + '.FPC_FacilityName)'
ENDWITH
* Here, I am forced to employ square brackets due to presence of embedded
* apostrophes
This.icDynamicFormCaption = ['Notes for '] + ;
[DTOC(C_AdmitDischarge.AD_AdmittedOn) + '-'] + ;
[DTOC(C_AdmitDischarge.AD_DischargedOn)]
* Here, I am forced to employ double quotes due to the presence of embedded
* square brackets as well as an embedded apostrophe
This.icDynamicFormCaption = "[Notes for McDonald's]"
* Alternatively, I could employ square brackets as the main character
* delimiter:
This.icDynamicFormCaption = ["Notes for McDonald's"]
(Regardless of what character delimiters you prefer to employ, I recommend that you be consistent!)
Posted by abergquist on September 11, 2008 | Permalink | Comments (0) | TrackBack (0)
September 04, 2008
Best practices when macro substituting
When working with macro substitutions …
1) bring “closure” to them
Get in the habit of always “closing” your macro substitution with a period (“.”); for example:
&lcSQL.
That way, when you employ macro substitution as part of an object hierarchy, VFP will properly parse the line; for example, if you have a form with a commandbutton whose .Name is ' cmdButton':
The following code sets the .Caption of 'cmdButton' to 'Process':
LOCAL lcCommandButton
lcCommandButton = 'cmdButton'
ThisForm.&lcCommandButton..Caption = 'Process' && Two (2) periods before .Caption
whereas the following code triggers a “Property CMDBUTTONCAPTION is not found” error:
LOCAL lcCommandButton
lcCommandButton = 'cmdButton'
ThisForm.&lcCommandButton.Caption = 'Process' && Only one (1) period before .Caption
2) don’t embed them
lcControlName = 'cmdButton'
Replace the cryptic, embedded macro substitution:
? 'oForm.&lcControlName.'
with the following, easier-to-read (and, therefore, easier-to-maintain) code:
? 'oForm.' + m.lcControlName
(The above should run faster, too, since it does not employ macro substitution.)
Posted by abergquist on September 4, 2008 | Permalink | Comments (1) | TrackBack (0)




