Current filter:
                                You should refresh the page.
                                Support Center

                                This example illustrates how to use Google Calendar API to synchronize ASPxScheduler with Google Calendar. Google provides the corresponding guidelines regarding the use of this API:

                                Google Calendar API 

                                Before using this API, make certain you have read and are in compliance with Google’s licensing terms. Next, you’ll need to generate a JSON file with OAuth 2.0 credentials to enable the Google Calendar API.

                                We have a corresponding KB article which contains a step-by-step description of how to generate this JSON file for the installed application type:

                                How to enable the Google Calendar API to use it in your application

                                The the OAuth 2.0 flow both for authentication and for obtaining authorization is similar to the one for Web Server Applications except three points:

                                1) When creating a client ID, you specify that your application is an Installed application. This results in a different value for the redirect_uri parameter.
                                2) The client ID and client secret obtained from the API Console are embedded in the source code of your application. In this context, the client secret is obviously not treated as a secret.
                                3) The authorization code can be returned to your application in the title bar of the browser or in the query string of an HTTP request to the local host.

                                Please refer to Google OAuth 2.0 documentation for more information.

                                After you generate this JSON file, start the "oauth2callback.aspx" page for authorization. 

                                1. Enter the email address you used to generate the JSON file.
                                2. Select the JSON file on the client machine by clicking the "Browse" button.
                                3. Click the "Get 'Client ID' and 'Client secret' from file" button to upload the selected file and enable the Google Calendar API.
                                4. The application should be navigated to the "Default.aspx" page.
                                5. Select a corresponding calendar to synchronize with the scheduler storage.

                                P.S. To run this example's solution, include the corresponding "Google Calendar API" assemblies into the project.

                                For this, open the "Package Manager Console" (Tools - NuGet Package Manager) and execute the following command:

                                Install-Package Google.Apis.Calendar.v3

                                The synchronization procedure implemented in this example has the following limitations: 

                                -     Recurring appointments are excluded
                                -     Statuses, labels, reminders, and resource associations are not synchronized.

                                Show Implementation Details
                                Select file
                                • Default.aspx.cs
                                • AppointmentSynchronizer.ascx
                                • AppointmentSynchronizer.ascx.cs
                                • CalendarApiHelper.cs
                                • CalendarApiHelper.cs
                                • CustomEvents.cs
                                • CustomEvents.cs
                                • DataHelper.cs
                                • DataHelper.cs
                                • Default.aspx
                                • GoogleHelper.cs
                                • GoogleHelper.cs
                                • oauth2callback.aspx
                                • oauth2callback.aspx.cs
                                Select language
                                • C#
                                • VB.NET
                                Select version
                                • 16.1.4 - 17.2.7

                                If you need additional product information, write to us at or call us at +1 (818) 844-3383

                                FOLLOW US

                                DevExpress engineers feature-complete Presentation Controls, IDE Productivity Tools, Business Application Frameworks, and Reporting Systems for Visual Studio, along with high-performance HTML JS Mobile Frameworks for developers targeting iOS, Android and Windows Phone. Whether using WPF, ASP.NET, WinForms, HTML5 or Windows 10, DevExpress tools help you build and deliver your best in the shortest time possible.

                                Copyright © 1998-2018 Developer Express Inc.
                                All trademarks or registered trademarks are property of their respective owners