Hi,

The Calendar API discussion group is a better place for this question:

http://groups.google.com/group/google-calendar-help-dataapi

-alex

On Mar 27, 7:26 am, bobb <[EMAIL PROTECTED]> wrote:
> UPDATE:
> After all of the above, when I submit a batch request to this Uri for
> Calendar events:
>
>      "http://www.google.com/calendar/feeds/default/private/full/batch";
>
> I get a 401-Unauthorized exception. This is kind of strange, since I
> attached the authToken I got back from the login request to the
> service instance.
> Any thoughts on how to get around this?
>
> On Mar 27, 10:07 am, bobb <[EMAIL PROTECTED]> wrote:
>
> > Thanks, Frank, but I was hoping for something more specific. I
> > searched all the samples sources in the .net API kit. I found a couple
> > of usage instances among the unit test sources, but that's not great
> > as a comprehensive example. Looking at the .net api sources I managed
> > to figure out one approach that looked like it should work. Here's the
> > relevant code snipped:
>
> >             CalendarService service = new CalendarService("exampleCo-
> > exampleApp-1");
> >             service.setUserCredentials(userLogin, userPassword);
> >             GDataGAuthRequestFactory authHelper = new
> > GDataGAuthRequestFactory("cl","BinaryTree-Cal-Upload");
> >             service.RequestFactory = authHelper;
> >             string token = authHelper.QueryAuthToken(new
> > GDataCredentials(userLogin, userPassword));
>
> > In tracing into the code on this last statement, it seems to be doing
> > all the right things. The default account type is GOOGLE_OR_HOSTED,
> > which is what I wanted. The code is using an ASCII encoder, which I
> > find a bit strange (why not utf? What if I have DBCS content?), but
> > ok, whatever.
>
> > The account I'm targeting is a hosted company site, I even coded the
> > "@" as "%40" to be nice. The request is sent and the response received
> > without throwing. I look at the HttpWebResponse that's returned, and
> > the status is "OK". However, on this line:
>
> > TokenCollection tokens =
> > Utilities.ParseStreamInTokenCollection(response.GetResponseStream());
>
> > Sometimes it works fine, and I get the token, other times it throws an
> > Exception saying, "Stream is not readable".
>
> > So, my real question is, am I doing something wrong? And, if not, what
> > do I do to recover from the Exception?
> > TIA
>
> > On Mar 27, 7:14 am, Frank Mantek <[EMAIL PROTECTED]> wrote:
>
> > > sure there is. Go to:
>
> > >http://code.google.com/p/google-gdata
>
> > > Frank Mantek
> > > Google
> > > On Mar 27, 2008, at 9:36 AM, bobb wrote:
>
> > > > I've spent hours searching, can't find one. If it does exist, is there
> > > > a sample showing how to use it?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Apps APIs" 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-apps-apis?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to