Epoch ß1.3 © Jack Pritchard 1992. Welcome to the world of Epoch. This programme is a Test version, meaning that I am putting it into the Public Domain at this stage to see what sort of response I get to it. If you copy this programme and give it to others make sure that this doc file is copied with it. Epoch was written in GfaBasic v3.5 and compiled with GfaBcom v3.51E. So if you want all 2184 lines of source code drop me a line, two first class stamps and a disk. As it exists now it consists of two main parts, one being the calendar and the other the address/phone book. When the programme is first invoked it opens up a small window in the upper left hand part of the WorkBench screen in much the same way as Fenster or VirusX would. The idea is that you should start Epoch from your startup-sequence by entering the line: Run Epoch or RunBack Epoch WorkBench 2 users might want to try and put it in their WBStartup draw. As mentioned before there are two main parts to the programme, the address book can be accessed by first clicking on the Epoch window and then selecting Address from the pull down menu or with left Amiga-A. The calendar can be accessed by selecting Calendar from the pull down menu or with left Amiga-C. Before you run Epoch you must make sure that you have a logical device named Epoch_Files:. This is where the programme looks for the data files used with the address book and calendar. Amend your startup-sequence to include something like this: Assign Epoch_files: S: RunBack Sys:Utilities/Epoch The Address Book: Select Address from the pull down menu to activate the Address book. The first thing the programme will do is look for a file called 'Epoch_Files:Phone.Lst', if it can't find it you will be presented with a small requester window giving you three options. 1. Forget All About It 2. Create One Later 3. Have Another Go Forget All About It will act as if you hadn't made a selection in the first place, Create One Later will let you use the address book and save the file to disk after the session and Have Another Go will force it to look again. At this stage you shouldn't have any files in Epoch_Files: so click on 'Create One Later' so that we can proceed. When the Address Book window is displayed the first thing you will notice is the seven string gadgets titled: Name Street District Town County Country Telephone Number You should also notice that this is page one. In this version of Epoch you can have up to 284 pages each containing seven lines of text. To enter information into your address book simply click on EDIT and then in the string gadget(s) you wish to write to. Once you have finished click on EDIT again to take you out of edit mode. You now have one page of your address book completed. This page along with any others will be saved to disk AFTER you have left the Address Book. The Gadgets: SEARCH - To use the search facility simply click in one of the string gadgets (i.e. Name) and enter the text you wish to search for. If the gadget is not empty you can clear it by pressing left Amiga-x or by using the backspace/delete keys. Once you have entered your text click on SEARCH and a forward search will be activated starting from the next page and up to the end of the book. If no match is found you will be informed of this with a small window, click on YUP to continue. If on the other hand a match is found then that page will be displayed along with the page number. Clicking on SEARCH again will result in further matches being looked for. SEARCH will try to match the text you typed in with the entry on that line with every page in the book. e.g: 'RiC' in string gadget 'Name' will make a match with: (Without the ' of course). Richard Paul Ricter Jack Richardson But it would not match with 'Richmond' in the string gadget 'Town'. EDIT - This will put you in edit mode and enable you to input information into your address book. Click on EDIT again to take you out of this mode. NEW - This will take you to the first available empty page in your book. i.e. If pages 1 - 14 and 16-23 have entries then clicking on NEW will take you to page 15. If you then click on EDIT and use this page, NEW will take you to page 24. This is very useful in edit mode if you have a lot of information to enter. <-PAGE - Will simply take you back one page in your book. PAGE-> - Takes you one page forward. OK - End of session. This is the same as clicking on the close field of the window and will result in quitting the Address Book. Any changes you have made to your Address Book will then be saved to disk. __ Page:- |__| - The page you are currently viewing will be displayed in this box. Clicking in this box, entering a new page number and pressing return or enter will result in that page being displayed, even if it is empty. ORIGIN - This is almost the opposite of NEW and will take you back to page one. The same as clicking in the Page box and entering one. DELETE - If you want to delete a page simply go to that page and click on DELETE. You will then be given the option to change your mind. ALL - The same as DELETE only this function applies to the entire Address Book. ORDER - After you have used DELETE a few times you may notice that there are a lot of empty pages in between used ones. By clicking on ORDER all the empty pages will be stripped out. Because of a BUG in the Gfa Compiler the minimum size of the Phone.lst file must be 2100 lines. So you are advised to leave the writing of this file to Epoch and NOT to hack it about with a text editor. If you do muck about with it with the result that the file is then shorter (in lines) than it should be, the programme will re-run itself thus wiping out all information it has stored internally prior to saving. You've been warned.. The BUG in question lies with the RECALL command. The problem is that if you attempt to read in a file that is shorter (in lines) than the RECALL command is trying to read in you get and error 026 (or END OF FILE) message. The solution is to always make sure that the file, in our case phone.lst, is longer than the RECALL command can read in. Even if it is just filled with empty lines. That way the RECALL command will never reach the end of a file. If you manage to fix this problem Please, Please let me know. N.B. This problem is only with compiled programmes. The interpreter is fine. The above also applies to Calendar.lst as well. The Calendar: When the Calendar is first invoked it will go through the same motions as the Address Book. (You have been reading it all haven't you ?) The only difference is that it will be looking for 'Epoch_Files:Calendar.lst' instead. The Calendar opens up a large window in the middle of the workbench screen and follows the standard format with the days listed along the top and a grid consisting of five rows of seven boxes with another row of two to accommodate all the dates for that month. The title bar of the window will be displaying the current calendar date, (This will be the system date of your computer), and below the main display will be a range of buttons. This calendar is based on the Gregarian system and as such has a range from 1st January 1583 to 31st December 2899. It knows all about leap years both in normal years and century years, and as it can go back so far I thought it might be quite useful as a history log or just finding out on what day Great Great Great Great Great Aunt Maud was born. It also might be a good basis for Genealogical (or Family Tree) DataBase, what do you think ? The Buttons: SYSTEM - This will always bring you back to the system date. SET DATE - Change the System date. To Current Calendar Date - Whatever date the calendar is displaying will become the System date. To Default Date - Changes the System date to that of the computer. Whoops - Just that. CLEAR ALL - Not implemented. <---> - Is really two buttons. They are: <- - Looks for an entry before the date you are displaying. -> - Looks for one after. (More on this and entries later) NEW DATE - Clicking on this button will give you the chance to change the calendar date. You will be presented with seven columns of buttons. Columns 1 - 3 - The Date. i.e. 23 (23rd). Column 4 - The Month. i.e. 03 (March). Column 5 - The Century. i.e. 19 (19th Century). Column 6 - The Decade. i.e. 6 (The 60's). Column 7 - The Year. i.e. 6. So, if you followed the above example you would have entered the date: 23|03|1966. As you enter the date you will notice that it appears at the bottom the bottom of the window in a little box. You should also notice that on entering this function the Calendar date is already displayed, so if you want to change the date from 23|03|1992 to 23|03|1966 you need only amend columns 6 and 7. Once you are happy with your new date click on OK and it will be displayed on the calendar for you further manipulation. <-MONTH - Go back a month. MONTH-> - Go forward a month. <-YEAR - Back a year. YEAR-> - Forward a year. The Calendar itself: The Calendar is made up of 37 boxes, each of which is capable of displaying one date. By clicking on one of these boxes, say 14, the calendar is changed to that date and the information is reflected in the title bar. A further double-click on that box will result in the Event Planner being displayed in which you can enter/read information about that date. The Event Planner has a similar format to the Address Book and glossary of its functions follow: Date - This will be the date that you double-clicked on. It is not designed to be altered by the user but the ability has been left in. If you wish to alter it directly be sure to use the correct format, i.e. dd|mm|yyyy, or the entry will not show up on the calendar. Entries - The number of entries that are stored for this date will be represented here. Time, Venue and Event - These are all string gadgets in which you can enter information. EDIT - This is the same as the Address Book EDIT. Before you enter new information you must first put it in edit mode by clicking on EDIT. CLEAR - Same as DELETE in Address Book. Will only clear what you can see written. NEW - This will take you to the first available free space. It's only real use is when you are editing. <-ENTRY - Will scan back to see if there are any more entries for this date. ENTRY-> - Opposite to above. REPEAT - To use this function you must a) Activate a string gadget and b) Have something there to repeat. You cannot repeat nothing. Daily - Will repeat the information currently being displayed for one calendar month. Monthly - For one year. Yearly - For ten years. Forget It - Guess. FRESH START - Is the same as CLEAR only it will delete all the entries it can find for that date. OK - The same as clicking on the close field and will result in termination of the Event Planner. The above looks pretty clear to me but that's probably because I wrote the programme in the first place. So just to clear things up here is a small example of entering a birthday to be repeated yearly and a college course to be repeated monthly, both of which start on 19th March 1993. From the beginning: First of all activate the Epoch window by clicking on it once. Then select Calendar from the pull down menu or press left A-C. At this point two things are possible. One is that you haven't assigned Epoch_Files: to anything, and the other is that you haven't got the file called Calendar.lst, or both. If the first happens you will get a system requester asking you to 'Insert Volume Epoch_Files: in any Drive'. All you have to do is open up a shell and type 'Assign Epoch_Files: S:' (or where ever you want to keep it) and then click on 'Retry', alternativly you could just put in a disk called 'Epoch_Files:'. If the second happens you will be presented with an Epoch requester, click on 'Create One Later' and the Calendar window will open. You should now have the Calendar window slap bang in the middle of the workbench screen and be able to click on 'NEW DATE'. Do this now. What you should have now is a window entitled 'Select a Time Period to View '. Click on 19 in the second column. On 03 in the fourth column. On 19 in the fifth. On 9 in the sixth. And finally on 3 in the seventh. You should now have 19|03|1993 displayed at the bottom. Click on OK. The calendar will now be displayed and a fraction of a second later your new date should scroll down the window. The title should read 'Friday 19 March 1993' and the box numbered 19 should have a pushed in look. (Or pushed out if you are using default 2.04 colours). (If you are using default 2.04 colours try reversing the black and white. It looks much better). Click on SET DATE Should open up a small requester window. And then on 'To the Current Calendar Date' This is not necessary but it makes it easier to locate this month. Don't think that you have to do this every time you use the calendar, it's just an example of possible use. Double-click on the box with 19 in it. You should now have the Event Planner window in front of you with the date reading 19|03|1993 and Entries reading 0. Click on EDIT. The button will now be depressed. (In edit mode). Click in the Event string gadget. It should now have a cursor in it. And type 'Fred's Birthday'. (Or something). Click on EDIT again. The button will now be out. (Not in edit mode). No click on REPEAT. A small window should appear with four options. Select 'Yearly (For Ten Years)'. Now click on OK or the Close field of the window. The message 'Processing Data Please Wait' will appear, then the window will vanish. The calendar will now be displayed again but with one difference. If you look in the box for the 19th you will see this: - 1. That is to tell that there is 1 entry for that date. Click on the right hand side of <--->. This function will scan forwards until it find another entry. As you repeated the birthday yearly for ten years the next entry should be on Saturday 19 March 1994 then Sunday 19 March 1995 and so on until Tuesday 19 March 2002. Click on SYSTEM. (Or use the <-YEAR button). This will bring us back to March 1993. Double-click on the 19th again. The Event Planner will appear with the information that you just entered. Notice that Entries is now reading 1. Click on EDIT. Then click on NEW. This will clear the page ready for use. We will now be entering information for a monthly college course. Click Time's string gadget and enter '18:00'. Click Venue's string gadget and enter 'Epoch College of Technology'. And now in Event and enter 'Clait 1, Information Technology, RSA'. Click on EDIT again to get out of edit mode. You should now notice that Entries is reading 2. Now click on REPEAT and select 'Monthly (For one Year)'. Click on OK or Close. The calendar is now displaying '- 2' for the 19th End of Example...... I hope the above information is of some use, but as they say Practice makes Perfect. As i mentioned earlier this is only a test version and as such is not in any way complete. What there is of it I hope will be very useful and go some way to organizing your affairs. If you like it and would like a greatly enhanced version then let me know. Also i would be very grateful for feedback, please tell me what you think of it, (Constructive criticism only please), and tell me how it can be improved. Send your name and address, two first class stamps, envolope and a blank disk to:- Jack Pritchard 80 Privett Road Alverstoke Gosport Hampshire PO12-3SX England Epoch ß1.3 © Jack Pritchard 1992. The Author of this programme offers no warranty either expressed or implied. The Author accepts no responsibility for the performance of this programme which is supplied on an as is basis. By using this programme you do so entirely at your own risk.