Do internet calendar subscriptions (i.e. an ics url) automatically delete past events? - calendar

I subscribed to an internet calendar (the kind with a url ending in .ics), and I noticed that in my calendar clients, future events will update just fine, but past events quickly disappear. Is this standard behavior for internet ical subscriptions? Or is it due to a particular configuration, either on the side of the calendar provider, or on the side of my client?
I didn't see any options in my client for "sync older events" or anything like that, so if it's either of the first two scenarios, are there any programs (ideally on either Android or Windows) that could essentially subscribe to an internet calendar and copy its events onto a different, local calendar, so as to preserve them indefinitely?

After doing some digging, I've determined the following:
There is no standard time window that internet calendars sync events.
That is determined by the provider of the internet calendar, and cannot be changed by a subscriber.
There are no common, universally applicable utilities that automate the copying of events from one calendar to another (in part because, on non-smartphone operating systems, the storage and management of calendars varies wildly by client).
However, Calendar Cloner is a free, open-source program that can be compiled and run on Android, which does automate the copying of events from one calendar to another. It does not support much complexity in terms of rules, but it gets the job done.
The simplest viable alternative for Windows might be to subscribe to the internet calendar in Outlook, then write a VBA macro (perhaps based off this one) to copy events to a new calendar. (That new calendar could be synced to other devices via various plugins that sync Outlook with Google Calendar or CalDAV calendars).

Related

Synchronizing events of my system into most widely used calendars

I have implemented a (sports field) booking system. I would like to add one feature: when a customer makes a booking I would like to offer him the possibility to get/sync his newly created entry in his own calendar.
One solution what I already found is to create an iCalendar feed for the customer with his bookings. So he can take this feed (basically an URL pointing to a user-specific .ics file) and integrate it into his calendar applications (as most will support the addition of external calendars).
One bottleneck with this solution is that a good amount of customers use Gmail and its calendar. And it may take some time until Gmail refreshes external calendars. So it may take up to few hours until the newly created entry appears in the customers calendar.
Of course there's no such problem when customer is using calendar apps which offer more frequent or on-demand synchronization.
So my question here: what other solutions can you recommend? An export in a file for the newly created event? Or any other technology to sync our bookings with the most widely used calendars? What would be the most usable solution for customers?
If you want to be able to auto update / synchronise the booking by having the user subscribe, then the ics feed is the standard cross application way to do it.
If it is just one booking and is never going to be updated, then you could encourage them to import the ics file to their calendar which usually then appears within seconds.
You can also email them the ics file. It is then not subscribeable as it is NOT a url. How it is handled depends on their email and system setup, but most would offer import into their calendar. (Mine opens in notepad++) ;)

How do I repeat events in an ICS file every x seconds?

I'm trying to set up calendar events in macOS Sierra's Calendar that repeat every 2,551,440 seconds (which happens to be the synodic period of the Moon). This system uses the ICS specification.
Ultimately, I want a calendar that provides the Moon rise and set times for my location, and it also needs to list the Lunar phase (e.g. Full Moon, New Moon, etc.). I have found plenty of examples on the Internet where people have manually created the events, but that's incredibly tedious (one event per day for years!), and they're based on different time zones (and so are of no use to me).
I have seen from the ICS specifications that the file format itself supports events that recur every x seconds. I exported an event as an ICS file (from Calendar), and then edited the ICS file in a text editor, but I must've got the code wrong, as it didn't re-import into macOS Calendar with the correct repeat interval. Instead, it imported a single event with no repetition. It's also possible that I got the code right, but Calendar discarded it upon import...
Can someone please explain how to go about doing this?
I found the RRULE Generator, but that only supports hourly intervals, not seconds, and so is not precise enough for my needs.
I considered running a bash script to generate the event (which would run as a cron job every 2,551,440 seconds), but that would only give a month's notice. I'd prefer to have it set up indefinitely.
Another option may be to write a script in Python to create individual ICS event files; this would also be tedious...
I understand that this can't be done in Calendar directly; the solution will most likely be manually editing each ICS file to set up the recurrence correctly, and then importing them into Calendar... I just don't know how...
...or is there a calendar application somewhere out there that lets you set up events that recur every x seconds? If so, I could create the event in that, export it and then import it into Calendar...
Thanks in advance for any thoughts.
So, I figured this one out.
Apple Calendar, Google Calendar, and pretty much all calendar applications don't support events that repeat every x seconds. The ICS format itself does, just not the programs.
The Moon is in an inclined orbit, so this is an inappropriate solution for what I wanted anyway.
The US Navy has an API that publishes rise/set and phase data for the Moon. I saved the responses from this page (a JSON file), and did some Python code to extract the required data, and then made a Python script to create the separate .ICS files for each event (one event per Moonrise) (i.e. not one event that repeats every x seconds). I then imported those ICS files into macOS Calendar.
Hope this helps someone else who needs to deal with a similar situation in future...

Export multiple database records to iCal or gCal

I'm building a simple scheduling application for a client. It allows teachers to create a calendar of assignments for their students. I'd like to offer the ability for a student to add ALL assignments to their calendar at one time. Say there were 20 assignments over a 4 week period. This functionality would allow the student to download a single file, or follow a certain feed, to add all 20 assignments to their calendar at one time.
In my head this would be a single iCal file, but I'm not sure if iCal works that way. Alternately, each course /course/basket-weaving-101_51/ would have an RSS feed /course/basket-weaving-101_51/cal/ that could be followed.
Does anyone have experience with this, or could offer guidance?
Yes, one feed program that accepts parameters via the url could be used to offer a subscribeable calendar feed at whatever level of detail you wish. I say subscribeable as that, at a student level ... /student_id_or_name?feed=ics would offer the students the most convenient solution. They could subscribe once and then all the courses assignments that they are signed up for all courses over time could automatically appear as their calendar app refreshes the feed.
A single assignment could also offer a feed of the one 'event'. But that should probably be imported into their main calendar, rather than subscribing!
Note subscribing is different to importing - your help instructions need to make that clear as it is up to the user what they do with the feed.
Import(or add to calendar) is a once-off and will not update with new events/assignments.
Subscribing as a separate calendar I find much preferable as most calendar apps will let one check and uncheck the calendars as you need them. I have mykids timetables subscribed (and public holidays etc) but that's a very busy view, so often I just untick them
for a cleaner view.
You need to get familiar with the treatment of ical by the different calendar clients (outlook, webmail) before you can decide how best to target them. In general, they have two modes for treating ical: "accept an invitation" and "subscribe to an internet calendar".
The big advantage of "Accept an invitation" is that your events go into the user's calendar, and generate reminders and so on as if the user had created the event. The disadvantage is that you need to send your invitations one "event" at a time by email, and, particularly in Outlook, they may need to be viewed as mail before they appear in the calendar. If you're sending out 20 or more assignments, this may feel like spam to the recipient.
"Subscribe to an internet calendar" is a little misleading in that an ical feed is not a feed. You put the "whole calendar" on a website, and the client poles the website. Outlook and webmail clients are generally happy to display these calendars, but "importing" the events into the user's own calendar is a bit clunky. Gmail and webmail display the info on the same grid by default. Outlook displays a new grid for each calendar.
Modifications are a bit more complex for the subscription scenario. You will likely want to regenerate the whole calendar for affected students, whereas in the invitation scenario you just send one mail with the changed event.
Even so, if you have a database with courses, students and enrolments, you could do a nice little app that generates an ical per student, names it with their student number, and whacks it in a calendars folder. The student subscribes once to http://myuniversity.com/calendars/12345.ical, and each semester all their assignments are automatically in their web calendar.
Be careful with the subscription link. If tens of thousands of students subscribe to (pole) a dynamically generated calendar, you are going to have a lot of needless processing, and quite likely a performance headache. You want to be generating static files, then let your webserver negotiate with the client whether they need to be resent.

Best practice for updating silverlight deployment that is actively being used

I am currently running a SL3 project where we are in a highly iterative development mode with about 25 active test customers. I am making small changes at a clip of about 4 new builds per day. It is important to know this application is mission critical line of business for these 25 people, it is the tool they use all day to do their work so they are using it constantly and often launch their browser and the app in the morning and never close it until the end of the day.
The challenge is that when I make an update to the application I have no clean way to notify the users, in most cases this is ok as it is rare that I introduce a data contract change or something that would be a classic 'breaking' change to the app/service. Users keep plugging along and will get the change next time they refresh.
Right now we have resorted to emailing everyone and telling them to force refresh or close the browser and log back in.
Surely there is a better way...
Right now my train of thought is to have a method on the server that compares client xap versions and determines if the client being used is the most up to date, if so I will notify the user and make them update.
What have you done to solve this problem?
One way of doing it is to use a push mechanism (I used Kaazing Websoocket Gateway but any would do). When a new version of the XAP is released a message (either manually entered into the system by admin or automated triggered by XAP file change event) would be sent to all the clients. In the simplest scenario some notification would be shown to a user (telling him that a new version is released and the application needs to refresh) and then the app would refresh (by simply reloading the page) saving user's state if necessary.
If I would do this I would just keep it simple. A configuration value in web.config and a corresponding service method that simply returns that value (the value itself could be anything, but a counter is probably wise). Then you could have your Silverlight app poll that service method at regular intervals. Whenever the value changes (which you would do manually when you deploy a new version), just pop up a dialog telling the user to refresh the browser or log in/out. This way you don't have to force them to refresh every time. If you go with the idea of comparing xap file versions they will always be required to refresh, even for non-breaking changes.
If you want to take it further you could come up with some sort of mechanism to distinguish between different severity levels. For instance, if the new config value would contain the string "update_forced", you could force the users to reload the app by logging them out automatically (a little harsh, perhaps). If it contains the string "update_recommended", just show a little icon at the top right corner saying that there is a new version and that they should upgrade in their own time.
Granted, this was targeted at Silverlight 3, but with the PollingDuplex client and such in the newer versions of Silverlight, you could publish an "Update Now" bit to the clients, and build a mechanism in the client to alert the user that there is an update that is now out... that they should update it shortly, etc. You may even be able, through serialization and such, to save the state that they are in when they close the app to reload it.
We've done stuff similar with a LOB app that we built, so that as users are changing things, the rest of the userbase sees those changes immediately. Next up will be putting the flags in to change authorization and upgrades "on the fly" if you will.

How to switch users in a smooth way in a Point-Of-Sale system?

I am designing a Point-Of-Sale system for a small shop. The shop just have one Point-Of-Sale but often they are one to three users (sellers) in the shop. Each user have their own user account in the system so they login and logout very often. How should I design the login/logout system in a good way?
For the moment the users don't use passwords, because it takes so long time to type the password each time they login.
The Platform is Windows Vista but I would like to support Windows 7 too. We use Active Directory on the Network. The system is developed in Java/Swing for the moment, but I'm thinking about to change to C#.NET/WPF.
I am thinking about an SmartCard solution, but I don't know if that fits my situation. It would be more secure (which I like) but I don't know if it will be easy to implement and smooth to use, i.e. can I have the POS-system running in the background or started very quickly when the users switch? Are SmartCard solutions very expensive? (My customers are small shops) Is it preferred to use .NET or Java in a SmartCard solution?
What other solutions do I have other than passwords/no passwords/smartcards?
How should I design the login/logout system in a good way?
Is there any good solution using SmartCards for this purpose?
I would like suggested solutions both for C#.NET/WPF and Java/Swing platforms.
I would like suggested solutions both for Active Directory solutions and solutions that only use one user profile in Windows.
How is this problem solved in similar products? I have only seen password-solutions, but they are clumsy.
An interesting solution is to use "Fast User Switching", i.e. the capability to have multiple user sessions open on the same PC. The POS software could be launched through the Startup folder of each seller account and would stay active in each seller session.
I thought that being in a domain (i.e. using Active Directory) disables Fast User Switching, but according to The old new thing, this was true on XP only. I just checked with my Win7 machine at work: it is in a domain but still has the "switch user" menu item.
The main advantage is that if your software is already multi-user aware, you don't need to change it.
I should have made the Fast User Switching check before writing what is below, because this seems to be the simplest solution. Here are other ideas, anyway.
Another solution is what you mention of having a single Windows user but several "virtual users" that your application manages. A smart card is a good way to implement a pseudo-login. In C++, the API allows detecting the removal or insertion of a card, so the application could detect this and read the card after insertion to know who's currently in front of the computer. .NET can easily call this API through P/Invoke; I don't know much of Java, except that JNI could be a solution to call the native API if there is no managed library that publishes this capability.
What should be done is researching the different types of card and how to talk to them, as your app should use a card that does not require a PIN to be accessed (or you are back to the slow login system, except if tying a 4-digit number is not considered too slow).
I've seen restaurants where waiters insert a key into the cash register in order to be identified. I googled "cash registers" but could only find a complete solution package, rather than the components like a key reader.
An almost idiotic question is: how much security do you need ? Does it make sense to have big buttons on the first screen of the app, where people click in order to tell the system who they are ? When they are done, they click on a "Finish" button and the app goes back to the "identify" screen. I've put this at the end because it is so simplistic that it has a low probability of being useful.
I'm not familiar with a broad range of smart card provider solutions, but I know Gemalto has a .Net friendly setup. Most others are geared to Java, but support is widening.
With regards to switching user sessions and your application, it depends on how "heavy" your application is. If your app requires quite a bit of start-up time / resources then you might consider creating the basic application as a service on the machine which can run in the background continuously and then you can load a light-weight UI to interact with the service with each user session (maybe launch via Startup menu).
There is a C# project on CodeProject which provides a framework for interacting with smart card services in windows - might be interesting reading.
I had a chance to work with the Open Source Computer Vision library (OpenCV)
in one of my past projects and its "Face-Recognition" is what you're after. It is written using native code, but can be easily used with Java, .NET, Android, iOS. All you need is a webcam and a button "Switch User" with the onClickListener that will take a picture and compare it with the images of your employees. Advantage? Once the picture's taken, it gets processed in less than 10ms. And as Timores mentioned earlier, once the face is recognised, you simply switch the session. Simple yet effective solution. Good luck!
maybe you want to think about using barcode scanner... probably you already have this device on POS ... my software for bars and restaurants use barcode scanner to recognize users. You have 2 options for using: first, user must log in with own barcode card, then he can use the application ... the second is better, everyone can use application, but to print the receipt user must use barcode card. After then he is responsible for that amount on this receipt.

Resources