I.T. Discussion Community!
-Collapse +Expand
DBA
Search DBA Group:

Advanced
-Collapse +Expand DBA Store
PRESTWOODSTORE

Prestwood eMagazine

October Edition
Subscribe now! It's Free!
Enter your email:

   ► KBDesktop Data...   Print This     
 
DBA Desktop Databases:
Version Information
 
Posted 13 years ago on 10/9/2006 and updated 8/1/2007
Take Away: Is there a right way to handle version information in our projects? Could we do a better job of it?
 A blog topic from wes's Blog

KB100404

Programs have versions. We all know that. But is there a "best" way to handle version information? Are we doing all we can to make it truly useful?

As for the first question, I'll let Windows make my argument for me. Open Windows Explorer and mouse over a few executables, and a few DLLs. Notice the little pop-up window that appears as you hover over a file? It shows version info - at least for many of your programs. Right-click a file, choose Properties, and there it is again - version information.


This doesn't happen by accident, and it won't happen if we put our version info in simple constants, string variables, or even text labels. Windows is pulling this information from the Version Info resource linked in your executable and, if you want it to show up like the pros do it, that's where you must put your version info, too.


Tools, like Delphi, have long made it easy to populate the version info resource (see Project | Options | Version Info). Unfortunately, many tools, Delphi included, have never bothered to make it easy for the developer to "get at" the version info in their code.


Fortunately, many third-party code libraries and components have long offered this functionality. My personal favorite (for Delphi) is the TStVersionInfo component in Turbo Power's SysTools library. This is now available as free, open source at SourceForge.net.


TStVersionInfo is a snap to use, so I won't go into any of the details.


As for the second question, "Are we doing all we can to make it truly useful?," I just realized that I wasn't. Turns out we have one end user that virtually never reports version information correctly in his emails to us. He transposes numbers - or pulls them out of thin air - we're not sure which.


So what's my part in that problem? Well, I've been using a simple text label (TLabel) to display version info. That works great, but there's one problem with it: Users can't copy and paste from an ordinary text label!


The solution is obvious: Display version info in a control that supports copying to the clipboard. In Delphi, TLabel and TMemo are good candidates. Just make them Read-Only.


Blog Entries!

1 Comments.
 Contribute to this open topic blog!
Comment 1 of 2
How is this discussion thread related to business analysis?. I am a new member and am trying to understand the website structure. - Thanks.
Posted 12 years ago

Comment 2 of 2

Great question!

I wrote the post, and this is not the place I intended it to land.  I'm looking into it now.

Thanks for the good catch.

Wes.

Posted 12 years ago
 
Comment on this blog topic...
...
Sign in...

If you are a member, Sign In. Or, you can Create a Free account now.


Anonymous Post (text-only, no HTML):

Enter your name and security key.

Your Name:
Security key = P1142A1
Enter key:
Blog Contributed By Wes Peterson:

Wes Peterson is a Senior Programmer Analyst with Prestwood IT Solutions where he develops custom Windows software and custom websites using .Net and Delphi. When Wes is not coding for clients, he participates in this online community. Prior to his 10-year love-affair with Delphi, he worked with several other tools and databases. Currently he specializes in VS.Net using C# and VB.Net. To Wes, the .NET revolution is as exciting as the birth of Delphi.

Visit Profile

 KB Article #100404 Counter
7507
Since 4/2/2008

Follow PrestwoodBoards on: 


©1995-2019 PrestwoodBoards  [Security & Privacy]
Professional IT Services: Coding | Websites | Computer Tech