I have a volunteering app that I made in Unity. When someone signs up for a volunteer event, I want to show them a confirmation page that lets them add the event to the calendar of their choice.
Google Calendar is easy because I can make a string for the URL, and use Application.OpenURL to take them out of my app and to the right link. From there they just need to (1) not touch anything AND (2) press OK and it's added to their calendar. (This is working fine!)
Microsoft Outlook and Apple Calendar are tougher, though. They use these ICS files. So I figured I would generate an ICS file and have them open it when they press the button, which should automatically take them to the correct calendar app on their phone. But it looks like Android and iOS don't allow Unity to use OpenURL to open local files on your phone anymore...
Has anyone solved this? What should I do?
TLDR: OpenURL works for Google Calendar links to the Internet, but not for local files.
Related
I am developing a web app to manage events using the Blazor server-side framework. One of the requirements is a button that allows the users to add events to a calendar of choice, mainly google calendar, outlook calendar, and the local calendar of the device they are using.
I managed the google and outlook calendars using tag with the appropriate links and parameters, now the last thing I want is to have a button that when clicked opens the default calendar app and displays the event info. I managed to convert the event model into an appropriate icalendar standard format file, but couldn't figure out how to open the calendar app and send it the event file.
The scenario I'm trying to solve for is this: as a User who wants an organization's events on my Outlook/Office365 calendar, I want to be able to download and important a calendar from a link without first having it download and then me have to search for the file to import to my calendar. I want the process to be (mostly) automatic. I want the process to be similar to how I can do in Google Calendar, or in Yahoo Calendar.
This answer gives a link for programmatically adding a feed to Google calendar, which works! Now I need a similar url for Office365 (another answer gave me one for Yahoo). I have searched everywhere, but almost all the answers I've found don't answer this question; rather, they simply say how to add individual events, not feeds. Or they tell the user how to manually subscribe. In my case, I have the feed all ready to go (it's an .ics file), I just need to give the user a clickable link so the process of adding it can happen automatically, with the usual sign in/permissions that Office 365/Outlook requires.
So what is the URL for Office 365 that I can use to create a link to my ical/ICS feed like with the other two services?
EDIT: To clarify - I have the calendar already in an .ics file, and then when the user clicks the link, their Office365 should open and ask if they want to import the calendar, the way gmail does. How do I make that happen?
And the half answer is the webcal protocol. Webcal mostly does what I want. I have to change the URL to include the different protocol and voila! I get prompted on Windows about what I want to do with the link. The same thing happens on Mac.
The link looks like this - webcal://myhost.com/myical.ics. Unfortunately, it doesn't connect to Office365 as I've seen other services do, but when I attempt to view their code, it's obscured or otherwise unavailable. But this gets me much closer to where I need to be.
Re So what is the URL for Office 365 that I can use to create a link to my ical/ICS feed like with the other two services?
There is no such URL. There are instructions for an Office365 user on how to import or subscribe a calendar. https://support.microsoft.com/en-us/office/import-or-subscribe-to-a-calendar-in-outlook-on-the-web-503ffaf6-7b86-44fe-8dd6-8099d95f38df
If you intend that the calendar will be updated, then leading your users to subscribe to a URL that you update is a better way to go about it.
Imports are really only good for one off calendars that do not change.
Note that Webcal is an Apple unofficial identifier for .ics and is not the answer for cross platform, although many applications will cope with it.
How a calendar file (ics url) gets treated depends on how it is accessed and how the individuals default application settings has been setup. My browser settings for example are set to open .ics files in Notepad++ because I test/work with calendars. Most will have it open their calendar application. Then it also depends on the application.
I've already checked some questions here on SO but couldn't find much help...
This one, for instance, is from 2011:
Embed Google docs editor into webpage?
My users need to be able to edit their Word documents on my website, just like Google docs editor and Office 365. Since I couldn't find information on how to easily integrate those, my current attempt was to convert the Word document to HTML (using OpenXmlPowerTools.HtmlConverter.ConvertToHtml) show it in a HTML editor and after the user edited the content save it back to the file (using NotesFor.HtmlToOpenXml).
Is this going to work? Is there any way to integrate either Google Docs or Office 365 to my website, allowing user to edit their content right there? If not, is it possible to programmatically create a document, send it to Google Docs/Office 365 have the user edit it there and then get the document back to save locally again?
Box and Dropbox have done it:
https://blogs.dropbox.com/dropbox/2015/04/dropbox-and-office-online/
https://www.box.com/blog/introducing-box-for-office-online/
Thanks!
The only thing i've been working with is Office365, so my answer is based on that, but i think you would be able to do the same in Google Apps.
Right now it's not possible to embed a document from Office365 in your own website for editing, only for viewing, but i guess this might change at some point.
But what you could do is to create a document, upload it do OneDrive, get a link to that file and make a button to open it in Office Online, after the edit is done, then the file would be on the users OneDrive.
If you would like to get the file to your system, it's just a matter of getting access to the users OneDrive.
Most of the operations can be achieved with the Graph API, http://graph.microsoft.io/, and all of it can be done without the user having to do anything. You just need to get the right permissions for the app that gets acess to Office365.
Developing a booking website in MVC5 C# and once the user has booked I want to added the booked date to the user's calendar if they access the website via a mobile device.
I've been looking around the web to find if there is any solution but all I've seen are device specific solutions for Android or iOS mobile app developmemt. I want to look for a solution that will be tailored to access the calendar on all mobile devices or even just Android and iOS.
I want to know if this is possible and a starting point like a C# library?
For security reasons, you can't access the user's calendar directly from a web app.
What you can do, though, is providing him an iCalendar file that will contain the details about what he just booked. When opening such a file, the user will be prompted to add it to his calendar. Nice thing about this solution: it works for almost all platforms, mobile and desktop.
To generate the iCalendar file in C#, you can use DDay.iCal.
I've been looking for some information about the subject, the thing is I'm trying to open, read, write files in dropbox thru a WPF app. So far I found this video https://www.youtube.com/watch?v=fcT-Jt8rcdY and the problem is that it uses windows forms and also has to introduce username and password to login. I just want to use dropbox as a tool to save some files in the cloud without loging everytime the program want to acces to dropbox. Any ideas?
You can use DropBox Linker, a library for using DropBox in .NET WPF application.
http://dropboxlinker.codeplex.com