This makes sense, and it is what I looked for, however, I don't get
the exception until the next time I use the service (in my case it is
the service.Insert()).
This means that I need to check for the AuthenticationException on
every service call... Rather than on the setUserCredentials() call.
Thanks!
Bob
On Oct 29, 12:58 am, "Austin (Google)" <[EMAIL PROTECTED]> wrote:
> Hi Bob,
>
> setUserCredentials() throws the AuthenticationException when the
> authentication failed. You can detect this failure by catching this
> exception like this:
>
> try (
> myService.setUserCredentials(user, pw);
> ) catch(AuthenticationException e) {
> System.out.println('authentication failed');
>
> }
>
> Hope that helps,
> Austin
>
> On Oct 28, 7:54 pm, Carver42 <[EMAIL PROTECTED]> wrote:
>
>
>
> > Is there a way to verify the user has supplied the correct username
> > and pw when I call setUserCredientials()?
>
> > I am using a CalendarService object and when I call
> > setUserCredentials, I get no error if the user name and pw are
> > incorrect. It would be helpful if I could determine and correct the
> > problem within my login method.
>
> > Thanks,
>
> > Bob- Hide quoted text -
>
> - Show quoted text -
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Calendar Data API" group.
To post to this group, send email to
[email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/google-calendar-help-dataapi?hl=en
-~----------~----~----~----~------~----~------~--~---