1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Not found in class GoogleWebAuthorizationBroker Library Google.Apis.Auth.OAuth2

Discussion in 'Google API' started by insidedocument, Jul 3, 2014.

  1. #1
    Create an application for example https://developers.google.com/google-apps/calendar/instantiate but the library from Google not have the right class. What to do where to look;

    usingSystem;usingSystem.Threading;usingSystem.Threading.Tasks;usingGoogle;usingGoogle.Apis.Auth.OAuth2;usingGoogle.Apis.Calendar.v3;usingGoogle.Apis.Calendar.v3.Data;usingGoogle.Apis.Services;namespaceCalendar.Sample{
    classProgram
    {
    staticvoidMain(string[] args)
    {
    UserCredential credential =GoogleWebAuthorizationBroker.AuthorizeAsync(
    newClientSecrets
    {
    ClientId="CLIENT_ID_HERE",
    ClientSecret="CLIENT_SECRET_HERE",
    },
    new[]{CalendarService.Scope.Calendar},
    "user",
    CancellationToken.None).Result;

    // Create the service.
    var service =newCalendarService(newBaseClientService.Initializer()
    {
    HttpClientInitializer= credential,
    ApplicationName="Calendar API Sample",
    });

    ...
    }
    }}
    SEMrush
     
    insidedocument, Jul 3, 2014 IP
    SEMrush