To have events occur with reference to sunrise and sunset, the program needs these times. They are specific to the year and to the location. This module requests a text document from the US Naval Observatory, for the location and the year entered by the user. It loads the values into the SunriseSunset table for use by other modules, as required.
To run, it requires the SunriseSunset table to exist in the ep5BAS MS-SQL Server database. Click here to download the table definition.
Please note that dealing with Daylight Saving Time is not addressed in this code. The service provided by the Naval Observatory covers locations worldwide. If you have concerns about this code or wish to make a suggestion, please contact us by e-mail at code@ep5BAS.org.
Download the Visual Studio 2022 solution ZIPfile here.