c# - AdWords Get UserLists null entries but 17 items inside? -


i trying list of userlists on account, no entries though during debugging totalnumofentries 17. screen shot attached, ideas why cant see these entries are? (sorry details of debugger came out faint)

enter image description here

code:

                adwordsuserlistservice usrservice = (adwordsuserlistservice)user.getservice(adwordsservice.v201402.adwordsuserlistservice);                 selector usrselect = new selector();                 usrselect.fields = new string[] { "id","name", "size", "membershiplifespan" };                     //use predicates filtering, if needed, later.                 //predicate usrpredicate = new predicate();                 //usrpredicate.field = "name";                 //usrpredicate.@operator = predicateoperator.starts_with;                 //usrpredicate.values = new string[] { "poly" };                 //usrselect.predicates = new predicate[] { usrpredicate };                 usrselect.paging = new paging();                 usrselect.ordering = new orderby[] { new orderby() { field="name",sortorder=sortorder.ascending} };                 userlistpage userlistresult = usrservice.get(usrselect);                 if (userlistresult.entries != null)                 {                     return "yay!";                 } 

found problem, specified paging didn't specify how many entries, adding line fixed problem.

usrselect.paging.numberresults = 20;


Comments

Popular posts from this blog

apache - Remove .php and add trailing slash in url using htaccess not loading css -

javascript - jQuery show full size image on click -