1. Home
  2. Computing & Technology
  3. Visual Basic
photo of Dan Mabbutt
Dan's Visual Basic Blog

By Dan Mabbutt, About.com Guide to Visual Basic since 2002

It's not VB, but it's interesting!

Sunday December 7, 2008
I recently included my article about programmatically calculating leap years in the About Visual Basic newsletter. When I did it, I knew that my faithful reader (and frequent contributor) Peter Zilahy Ingerman, PhD would comment. And so he has! It's not VB, but it's interesting! ------------- Let me define a moment as a sufficiently small piece of time, a day as a contiguous set of moments (and, for the Julian and Gregorian calendars, that's 86400 seconds, since they use solar days; some calendars use lunar days), and a date as the name of a day. A calendar, then, is a systematic (one hopes) way of assigning dates to days. In your article you say that days were eliminated in 1582 as a part of the Gregorian reform. That's simply false. The date Oct 4 (Julian) was followed by the date Oct 15 (Gregorian), but not even the Pope could eliminate days. Similarly, the decree of 1751, that switched Britain and its then-Colonies from the Julian to the Gregorian calendar eliminated dates, not days. It is also worth noting that that same decree changed the start of the year from March 25 (as it had been for centuries up to and including 1751) to January 1 (starting in 1752). Hence, 1751 was a short year. As a side note, Quakers named months as "First Month", "Second Month", etc., so it can be a matter of confusion to genealogists doing research in that era, since in 1751 the First Month was March, but in 1752 the First Month was January. Finally, it amuses me to note that prior to Julius Caesar's reform, the Roman calendar interpolated an occasional month before the 6th day preceding the Calends (= first day) of March. Caesar's reform stipulated that when an additional day needed to be added, it would be inserted at that same place, and would be called the "second 6th day preceding the Calends". Hence, a leap year was referred to as a "bisextile" year, since it contained two 6th days, and, in modern terms, leap day is actually Feb 24, not Feb 29.
Comments
December 13, 2008 at 11:54 pm
(1) Altaf says:

Hi,
I have written few MACRO`s for VS 2005 IDE. The system never executes them. Even the sample MACRO dont run. Any reason for this?

December 14, 2008 at 11:05 am
(2) visualbasic says:

How do you know? Many macros (especially in the sample) don’t have a visible result.

In any case, you’ve given me an idea. I don’t believe there is an article on my site about Visual Studio Macros. I think I’ll write one.

Microsoft provides this page as a reference on how to run macros.

http://msdn.microsoft.com/en-us/library/a0003t62.aspx

Leave a Comment

Line and paragraph breaks are automatic. Some HTML allowed: <a href="" title="">, <b>, <i>, <strike>

Explore Visual Basic
By Category
About.com Special Features

Stay connected and entertained with reviews on tips on the latest HDTVs, cellphones and more. More >

Easy ways to connect two computers for networking purposes. More >

  1. Home
  2. Computing & Technology
  3. Visual Basic

©2009 About.com, a part of The New York Times Company.

All rights reserved.