Skip to main content

Posts

Showing posts from 2009

Xsd2Code - better than XSD

I've been working on a few ASP.Net projects and one of the key aspects of this project is creating some usable XSD schemas that are then translated into objects.

At first, I started using the regular xsd.exe that creates a class (in either VB or C#) from a schema with the simple statement.

xsd "myfile.xsd" /l:CS /o:"C:\MyOutput\" /c

But I always wanted to have this directly within Visual Studio. I'm sure there's another way (so please let me know) but then I found
Xsd2Code .net class generator3.0.

It does the same thing that XSD does but also lets you create add Serialize and DeSerialize options, making it easier to convert a basic XML file into an object.

var o = FormInstance.Deserialize(xml);

The best part is that it's a Visual Studio plug-in (from Codeplex of course), so you can right-click on an XSD file and have it generate the necessary code. By default, the Serialization methods aren't included - but it's an option right from the generate di…

Jun Tangunan's Nicely Designed Controls

Just because a lot of cool stuff exists in VFPX doesn't mean there are other sources for inspired design.Jun Tangunan has been showcasing a number of his creations on his Foxite site.

Following Craig Boyd's lead to create "good-looking" applications, Jun's collection currently includes:

- An awesome looking button class
- A custom TitleBar class
- A switchbox class
- A calendar sidebar class
- A non-ActiveX based Date Picker
Jun Tangunan : Presenting SSButton Class


I just wish Jun would put his goodies into VFPX so they can be packaged at some point.

Great work!

One Great Resume

VisualCV is a great service for consultants and just about anyone who is looking at building the next generation of resumes. But they also have a great sense of humour. Take a look at this CV

Tom's Planner | Online Project Planning

I first read about this tool over on TechCrunch and noted it down. I just tried it and have to say "wow".

Project Management can be hard but this tool makes communicating it super easy. Even better, the project manager can publish it online (with password protection for easier review)

It's certainly not as powerful as MS Project but many times too much time is spent filling in details that are never used when the most important part of handling a project is communicating where it's at.

Project files are stored on your own computer so you still have control over them but you can publish it, export it as a Project file or even just as an image.

The file format is simply a text file with details (this might be the beginning of a nice open standard project format)

This is a great online tool to do just that.

Thank You

On every day, we are thankful for our freedom. Thank You. To all of the veterans, of every nation, everywhere, who have given us that freedom.

Windows 7 - review for developers

(note: the title refers to a review for developers - this is not about how to develop specifically for Windows 7 but rather a review of Windows 7 from the point of a developer and how its changes may affect you.)

Ars Technica does a very detailed review of Windows 7, going through key features and also the left-over bits of Vista. I'm using Windows 7 and find when I move over to XP or even Windows 2003, I really miss many features and so definitely recommend upgrading but let's go through the details on the review.

I've been using Windows 7 on and off now in beta and in its public form for over a year. While I never could wrap my head and get totally into Vista (I typically used Windows 2003 as a workstation - but I had to install and remove it for Trish twice), my first impressions of Windows 7 were very positive. The way Microsoft has "fixed" UAC for security is HUGE and while I still get a few "Are you sure you want to" dialogs, it's far less frequ…

New Hentzenwerke Visual FoxPro Book

Jim Booth has released an update to the popular "Effective Techniques for Application Development with Visual FoxPro" book from Hentzenwerke.

Published by Rainer Becker (and dFPUG c/o ISYS GmbH) and Whil Hentzen in both English and German, the eBook covers Visual FoxPro pretty much from soup to nuts but as Jim notes, " Although there is a lot of Visual FoxPro specific information in the book, there are also discussions that transcend any particular development tool or language."


Hentzenwerke Moving from Windows to Linux

SWFox Conference on Twitter

For those who aren't attending SW Fox, they're doing a great job keeping people up with live streaming as well as call-outs to twitters - for example, Eric's first day wrap-up.

But as well, Joel Leach over on Foxite is also posting his thoughts bout it, including individual sessions, like Dealing with Legacy code by Alan Stevens.

SWFox Conference (swfox) on Twitter

What Is Your Best Experience?

Amazing how a post on one topic really touches on so many others. Anil Dash posts aboutCommunications and Perception, defending his role as a marketer and communicator. The one line that hits home is "By starting to place importance on experiences and appreciation instead of objects and consumption, we become more sustainable as a society while also becoming more creative as a culture."

Just last night, Trish and I were talking about music and concerts we've attended and certainly the best concerts we've seen were the ones that delivered the best overall experience instead of just the big artist (that's why seeing a Beatles cover band in the Cavern ranks right up there).

The best place by far to have an experience is in person - and one of those places, this year, for FoxPro developers, is Southwest Fox, starting today. Instead of just building a product, the opportunity to see how others are using it, and experiencing it, is invaluable. Attendees of any conference…

Visionpace: Liar, liar, pants on fire!

Dave Aring has a great post on commenting that isn't specific to VFP but in any development environment. He takes on the Scrum and Agile belief that "all comments are lies".

I will readily say it - last year at SWFox, I made the suggestion that you really don't need to comment your code (at least to a certain extent) if you are using Source code control. After all, when you change something, you check it in, explaining why you did it. (in addition, it was a diatribe against comment headers in code - don't make me read the top of a program to figure out what you did in line 4931)

After reading Dave's post, obviously trying to figure out WHY someone did something by reading through the change log might be a little tough - so you may want to comment it a little. I like Art's point : "it's good to comment *why* something was done (as opposed to commenting *what* something does)"

The problem isn't that all comments are lies or that comments don&…

What You Should be Doing Next Week:: Blogging Southwest Fox 2009

I was going to title this "What are you doing next week" but unfortunately, I can't make SW Fox this year.

But the session list totally rocks. From basic VFP topics to how to use VFP with SourceGear's Vault and Subversion and a cool keynote from Sara Ford, I'm really going to miss the learning and networking opportunities.

So here's hoping those lucky attendees will share the love and live-blog some of the great sessions, or better yet, U-Stream them.

Here's hoping....
Doug Hennig: Southwest Fox 2009 is Next Week!

Update: Eric Selje - Salty Dog Solutions - will be blogging here

Adam Barr on Leveraging Your Weakness

Adam has a great post about how managers can take what many perceive as a weakness and turn it into a strength.

His point is that if you consider a weakess is likely that the user is overdoing something, "which means that the person actually possesses a strength that they are just overdoing. Take away the overdoing and presto, what's left is a strength."

It only goes so far certainly - we are talking about personality traits (what quality is a developer who writes buggy code overdoing?).

I'm not so sure what the long term effects of promoting a weakness might be, but it is an interesting idea.

Do you have a weakness that you can "flip" into a strength?

Proudly Serving My Corporate Masters: Leverage Your Weakness

Social Media and Recruiting: ways to go?

This is a great 4 minute review of how social networking is changing the world...Some of the stats are pretty incredible to think about.

I've been off Twitter and FB for a while now but using LinkedIn and VisualCV when looking for contract work. What was interesting was that one of the recruiters I was talking to was starting to get into the habit of using LinkedIn for searching for people.

I'm sure in the US and other areas, this has pretty much already happened for recruiters months and years ago. What's different here though, is that these are federal government recruiters - one demographic that has not really embraced social media (at least in Canada).

At any rate, very interesting and well-done presentation.

Still think corporate participation in Social Media is optional? - Skrocki's Blog

Be aware of Gmail Scam

I use gMail and just received an email asking for information regarding account currency.

This is a major scam. Although this is being reported, immediate Google searches aren't turning up anything.

The emails are sent from verifyscess@googledesk.com and is cc'ing a "Gmail Team" address at accessaccount10@gmail.com.

Do NOT be fooled - this is most definitely a scam.

Gmail Scam Warning Code:VX2G99AAJ

Peter discusses using ARG Command Bars

FoxPro developer Peter Hart has started a blog to showcase his learnings when working with the Arg Command Bars library.

CommandBars is a fantastic library for FoxPro developers that replicates the Office command menus beautifully. Peter shows how it goes even further now with support for the Office 2007 interface.

Great place to learn how to use his tool even further from my earlier videos.


ARG-Software (Command Bars Library blog of a FoxPro developer)

Craig's DevLink - I like it when you agree with me

Craig has some great reviews of the recent DevLinks days in his area but this post caught my eye:
DevBlog: DevLink Day 2

Why? Two reasons:
1) This comment:
"Concepts such as what kinds of comments and how many are important. It turns out that most comments in code aren't needed. If you write self-documenting code, even fewer are needed."

Those who attended my sessions at last year's SWFox heard me state this numerous times in my session on Code Analyst - even to the point where it appeared I was suggesting getting rid of comments entirely.

In a recent project, though, it became even clearer - I only needed comments to bookmark where I may need to do future work.

Self-documenting code is essential to maintainable code - and while having methods like GetPubishingAcronymForABookTitle goes into overkill of how to name a method, naming your methods right is important regardless of the language.

On the other side of the coin, one of the tools used in a recent project was a .Net …

So long Newsgator (for me, at least)

Change is never easy.

I've been using Newsgator for several years now (even bought it when it was a commercial user tool) and have loved seeing it move from an upstart newsreader (congrats Greg!) to a great enterprise tool.

When Google Reader came along, I still continued to use Newsgator mostly for the great Newsgator Go (or mobile) version. I loved being able to read feeds on my phone without having to go online every time.

Sadly today, in my inbox, I received word that they are no longer going to support these tools for consumer use after August 31st.

Now I have to move all of the great clips (another great feature of Newsgator) to another reader. I don't mind Google Reader but I will really miss not having it on my Windows mobile device. That said, it may convince me to look at other phones now that one of my main reasons for staying away from the iPhone and others was NewsGator Go.

To their credit, Newsgator is providing some great transition tips encouraging users to move t…

dev{shaped} » Fun Developers book

dev{shaped} » Book has compiled a list of various developer-oriented posts (and comics) and put them into a creative commons book called Developers, developers, developers. It covers specific development topics (like continuous integration and language wars) to career advice (remaining valuable) and up and coming concepts. Plus it has a handful of very funny comics.

Sure, you can read a lot of these posts online - but now you can either a)buy it or b) download it in PDF.

PEM Editor Video Series for VFP

If you haven't tried out the VFPX PEM Editor, you may want to check out Jordan's video series here.

The PEM Editor replaces the Properties Window, Edit Property/Method, New Property, and New Method, and Document View tools in Visual FoxPro. Sound like a lot?

There are 8 videos in all, totaling less than an hour of your viewing time.

It's this type of tool, along with the Control Renamer, FoxTabs, Tabbing Navigation, among others, that shows the need for an installer for VFP that includes these great tools that improve the VFP IDE experience.

It's something that has been brought up numerous times before, in VFPX discussions as well as at last year's Southwest Fox.

Consider a single installer that runs automatically after a VFP installation (or on its own) that installs and sets up:
- PEM Editor
- Control Renamer
- FoxTabs
- Tabbing Navigation
- Automated Build
- the updated Sedna and FFC controls
- Alternate SCCText (if desired)
- Code Analyst

(the above are all tools t…

Southwest Fox Registration Saver Deadline Coming Up

Southwest Fox, the fantastic US FoxPro developers conference, has a special deal for registration with $125 off the regular $745 price.

Note: The deadline has been extended to July 7th, 2009 so sign up today.

The conference line-up looks amazing this year, just as in past years. One of the tracks that really seems to be fleshing out is the Technology Track, with sessions on Virtual PC, SourceGear Vault, Subversion and more.

Southwest Fox definitely has it all: great speakers, great sessions, great networking - a great experience for developers.

Death of a legend

While I don't usually use this site for personal thoughts, I do want to take a moment to recognize the death of Michael Jackson, a true legend in pop culture and someone who affected the entire world with his music in a positive way.

While his lifestyle was crushing and troubling, his legacy lives on through his music and his impact on the video generation. Like his music or not, he invented pop culture as it exists today (through video, music and celebrity). I think most of the world today has some memory of him, as I know I do.

Just a thought - his planned comeback tour should continue on - with other musicians (Justin, Usher, Smokey, Paul, his brothers to name a few) taking part in those 50 concert shows, paying tribute to him. The money could go towards the obvious litigation that will be coming.

As the Righteous Brothers sang, "if there's a rock'n'roll heaven," then Michael has just joined one hell of a band.

He will be missed but his music lives on. Rest …

Test Driven SQL Projects

SQL Server Central just posted part 2 of an interesting article on applying the techniques of test-driven development to a SQL project. The author, Andy Leonard, goes from describing basic tests for setting up your databases to writing tests for inserting and updating data.

It's good stuff for a variety of reasons. He noted in the first article that some of the techniques are simply good coding practices (drop and recreate) but by writing them up as test scripts as well as within the SQL itself makes the entire piece part of a regression test and can resolve lots of further problems. He also points out that unit tests mean different things to different people so ensure your definition is the same as others on your team.

I'll be the first to admit that I'm not following the full pattern of writing individual tests out for each of my tables (the firing squad can resume shortly) - but the overall approach that Andy describes is solid and depending on how you code, you might fi…

Linux ready for the desktop? Show me productivity first.

ZDNet has an article titled Linux Ready for the Desktop.

While I do enjoy Ubuntu quite a bit (at least on one desktop) and I would never doubt the usefulness of Linux on a wide variety of machines, my concerns over open source systems have become more widespread with issues about forks.

Linux is certainly a different scenario than MySQL but consider this - mySQL has been considered a viable alternative for commercial RDBMS' for how long? It's been around since 1994 but has only really become a force to reckon with in the past 10 years.

Certain incarnations of Linux are certainly ready for the desktop (OpenOffice is arguably a good alternative to MS Office - bloat and all) - but then so are an entirely cloud or web-based OSes.

My #1 concern with any OS that I'm going to place on my desktop is "does it make me more productive?" (an offshoot of that would be "does it make any of my clients more productive?")

I'm a firm believer that people will pay for …

Refactoring T-SQL

While much has been said about the benefits of refactoring application code (see VFPX Code Analyst), I typically haven't seen a lot of noise about refactoring T-SQL and stored procedure code.

The refactoring features found in SQL Manager tend to be more about refactoring your database design but not about the actual content of the SPs.

It's important to note that if you tend to rely on large stored procedures, then many of the same rules of refactoring apply:

1. Keep it short and sweet.
2. Make it readable.


So when dealing with a particularly unruly stored proc (over 1000 lines), I was quite happy to find Red Gate's SQL Refactor (here's a post from the lead developer).

Some of the features are pretty basic (renaming variables, etc) but the one of great interest was the Encapsulate as a new Stored Proc.

As with a number of tools that are add-ons to other components, its overall usefulness might seem limited if you are building your stored procs either using testing patterns …

Dealing with Font Sizes

Andy Kramek offers some great samples of identifying how long a string can be in a particular font. This is something that every UI designer needs to consider when dealing with screen design.

While many VFP developers will use FONTMETRIC and TXTWIDTH, Andy has wrapped it all into a fairly easy function to call.


Check it out here

SQL: Does a Field Exist?

In the FoxPro world, checking to see if a field exists can be done a number of ways:

=AFIELDS(la)
IF ASCAN(la,"FIELDNAME")>0

ENDIF

or

IF TYPE("FIELDNAME") = "U"

(I'm sure there are lots of other ways especially if you're already working with a data dictionary tool)

In T-SQL, there is no real equivalent however, you can do the same by using the INFORMATION_SCHEMA table.

While there is no shortage of sites on the web that will show you similar code (like this one), I wanted to post it here for any VFP devs who may be switching between DBFs and SQL.

IF NOT EXISTS( SELECT * FROM INFORMATION_SCHEMA.COLUMNS
WHERE INFORMATION_SCHEMA.COLUMNS.TABLE_NAME = 'MyTable'
AND COLUMN_NAME='MyColumn')
ALTER TABLE myTable ADD MyColumn decimal(10,2) NULL

Of course, this assumes that the table already exists but you can use similar approaches for tables as well.

IF NOT EXISTS(SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES
WHERE TABLE_NAME = 'myT…

VFPx Showcase: Control Renamer

When speaking about VFPx at last year's Southwest Fox conference, it became evident that there aren't a lot of avenues for finding out how to use various pieces of VFPx. So as part of the FoxShow, I'm creating videos designed to showcase VFPx components, starting with the Control Renamer.

If you have ever wanted to rename a control in a class or form but were hesitant because of missing other code references, the Control Renamer is definitely a tool you want to try.

Now, there are lots of areas where new options can be added into this tool - but they are primarily "extras" like setting color settings or some logging.

Check it out below!









New VFP 9 SP2 Hotfixes: Report Designer Bug Fixed

Rick Schummer just noted this on his blog but it bears repeating.

A bug that Cathy Pountney had reported with the VFP 9 SP2 Report Designer has been fixed and is available for download, combined with 2 other hotfixes.

As Rick points out:
"Hopefully this is just the third in a string of hotfixes we will see from Microsoft as they support the product we all love. Today is a very good day. This is one small step for VFP, one giant leap for VFP developers. "

Download it here


Windows 7: First Early Impressions on VPC

First off, let me say I do HAVE Vista on my laptop and find it very annoying compared to Windows XP. ( I wanted to state that after Kevin Hoctor's comment on twitter.)

Vista has moved XP into a more secure environment but along with it came UAC, which to this day annoys me and makes me feel like I have to do three steps when I only used to have to do one in XP.

So before committing myself to running a beta product that is supposedly faster than its predecessors, I put it onto a Virtual PC.

Certain UI elements (like the Taskbar Properties) have been cleaned up for which I'm thankful. I still DON'T like the new Start menu - I don't think it's taken me away from SlickRun.

I did get some BSODs when installing the Virtual Machine Add-ons ( I couldn't give it as feedback using MS connect - although part of the program, it wouldn't say I was part of it).



Still, I installed Foxfire! ( a VFP app) on it (and while I had to Run As Administrator to get it to work), it wor…

A New Year...A New Month...A New Technology...

I have (first correction - thanks Matt!) been pulling together links for a larger "start of the year" post and decided to scale it back and try something a bit different. The various sites that AKSEL manages will be going through a "re-branding" exercise in the near future but one of my goals this year is to follow Chris Brogan's Three Words idea (Freedom. Consistency. Communication - I'm still deciding...) as well as working in some of Mark Riffey's ideas into my weekly schedule.

Rod Paddock asked "What's in a title" - and pointed out that one thing developers can do to become better developers is to adopt more agile practices - and he lists several practices and his experience with them.

That's a great goal for developers but what about "database developers"? There are lots of developers out there but almost every role needs to be qualified further: web developer, application developer, database developer. Are there other qua…

Farewell Friend

Late last night, sad news traveled around the FoxPro community about the passing of Ceil Silver. While she had been battling cancer for quite some time, one would never know it from her constant enthusiasm. She was a great colleague and a good friend. She will be missed.

If you are so inclined, the charity of choice (according to her daughter, Rachel) would be the NYU Cancer Center where she was being treated.

Her daughter has updated her blog here.

Andy Kramek's post