I will tell what i am doing :

1.
req.add(req.newFetchPersonRequest(opensocial.DataRequest.PersonId.VIEWER),
"viewer");
2.
req.add(req.newFetchPeopleRequest(opensocial.DataRequest.Group.VIEWER_FRIENDS),
"viewer_friends");
3. req.add(req.newFetchPersonAppDataRequest('VIEWER', 'comps'),
'data');
4. req.add(req.newFetchPersonAppDataRequest('VIEWER_FRIENDS',
'comps'), 'viewerFriendData');
5. req.send(onLoad);

In line 4, I am getting my application data ('comps') for all the
friends of the viewer. If my application is not installed in even one
of my friends' profile, the total thing goes wrong and even the
viewer's information is not sent back. I am getting: ==TypeError:
data.get("viewer") has no properties==


On Feb 26, 9:57 am, pradeep <[EMAIL PROTECTED]> wrote:
> Thanks Dinesh and Jason.
>
> It occurs when the viewer has not installed my app.
>
> How to get the return error code? and what are the possible error
> code.
>
> On Feb 26, 1:29 am, "Dinesh Kumar Subramanian"
>
> <[EMAIL PROTECTED]> wrote:
> > Hi,
> > This is expected error.  I have tested it. This will occur only if the
> > viewer dosent have your app installed. In that case you may need to
> > check for the error code unauthorized for viewer and make your app
> > work accordingly.
>
> > One way will be to prompt the user to add your app.
> > Hope this helps
>
> > Regards
> > Dinesh
>
> > On Mon, Feb 25, 2008 at 1:37 PM, Jason <[EMAIL PROTECTED]> wrote:
>
> > >  Hi!
>
> > >  Your code snippet works as expected at this end. If you are still
> > >  receiving this error, can you reply with a link to your full source?
> > >  This will help me debug your issue quicker. Thanks!
>
> > >  - Jason
>
> > >  On Feb 25, 5:23 am, pradeep <[EMAIL PROTECTED]> wrote:
> > >  > I am getting the same error since today morning.
>
> > >  > ---  data.get("viewer") has no properties
> > >  > ---  [Break on this error] var viewer = data.get('viewer').getData();
>
> > >  > I am using
>
> > >  > var req = opensocial.newDataRequest();
> > >  > 
> > > req.add(req.newFetchPersonRequest(opensocial.DataRequest.PersonId.VIEWER),
> > >  > 'viewer');
>
> > >  > to fetch the person's data.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Orkut Developer Forum" group.
To post to this group, send email to opensocial-orkut@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/opensocial-orkut?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to