Quantcast
Channel: SharePoint 2013 - Development and Programming forum
Viewing all articles
Browse latest Browse all 7589

How to get listitems from Sharepoint online using REST based on webid and listid

$
0
0
In my JavaScript code I have a webid and a listid in a sharepoint form page.

I'm trying to construct a rest url to get to the infomation in the list.

I cant figure out the url to get at the lists items.

My WebID is 33213c5c-30e5-468c-87f7-52b48a7b6a3d
My ListID is d38444af-dd7f-404b-9e75-b1f8c6cdee7d

When i go to

https://xxx.sharepoint.com/_api/web/webs?$expand=lists,lists/items&$filter=(iD eq guid'33213c5c-30e5-468c-87f7-52b48a7b6a3d' )

I get all items in all lists on the specified web. But when i go to
https://xxx.sharepoint.com/_api/web/webs?$expand=lists,lists/items&$filter=((iD eq guid'33213c5c-30e5-468c-87f7-52b48a7b6a3d' ) and (Lists/Id eq guid'd38444af-dd7f-404b-9e75-b1f8c6cdee7d' ) )

Sharepoint complains saying  'Field or property "Id" does not exist'

I can probably do this using multiple requests (get the web, then get the list), but the component I am working on needs a single url to access the listitems,

Can this be done?


Viewing all articles
Browse latest Browse all 7589

Trending Articles