The selector field names are case sensitive. You need to use *CurrencyCode *and not *currencyCode*, etc.
See list of field names here: https://developers.google.com/adwords/api/docs/appendix/selectorfields#v201209-ManagedCustomerService Oliver On Thursday, November 29, 2012 6:38:39 PM UTC, Arun Kumar wrote: > > Hello Team, > > My self Saurav Sharma from Smartdata Company. > > As I am using the Google Adwords Api to get the Clicks , Impressions on > the Particular Ads using the Test Account of the Google Adwords. > > > Please help me to find the List of the Clients present in the Google > Adwords account. > > > Also Please provide the help that Is the developer token always required > to get the "CampaignService" Clicks and Impressions? > > > > As I am using the Following Code for the ManagedCustomerService > > > > (user.Config as AdWordsAppConfig).AuthorizationMethod = > AdWordsAuthorizationMethod.OAuth2; > > OAuth2Provider oAuth2 = new > OAuth2Provider(user.Config); > > > > > user.Config.OAuthConsumerKey = " > 705284013785.apps.googleusercontent.com"; > user.Config.OAuthConsumerSecret > ="wJaVUN26Ms5KYJgXY4zKZoXD" ; > > > oAuth2.AccessToken = Session["SecretGoogleadwords"] as > string; > oAuth2.RefreshToken = Session["Googleadwords"] as > string; > > > user.OAuthProvider = oAuth2; > > (user.Config as AdWordsAppConfig).UserAgent = > "Webpresence"; > (user.Config as AdWordsAppConfig).DeveloperToken = > "gopR7WQ1nGJAiqPgiyeqKQ"; > > > (user.Config as AdWordsAppConfig).ClientCustomerId = > "773-963-1081"; > (user.Config as AdWordsAppConfig).OAuth2AccessToken = > Session["SecretGoogleadwords"] as string; > (user.Config as AdWordsAppConfig).OAuth2RefreshToken = > Session["Googleadwords"] as string; > (user.Config as AdWordsAppConfig).AuthToken = > Session["SecretGoogleadwords"] as string; > > > ManagedCustomerService accountdetail = > (ManagedCustomerService)user.GetService(AdWordsService.v201209.ManagedCustomerService); > > > Selector SelectorDetail = new Selector(); > SelectorDetail.fields = new string[] { > "name","currencyCode","dateTimeZone" }; > > ManagedCustomerPage paged3 = accountdetail.get(SelectorDetail); > if (paged3 != null && paged3.entries != null && > paged3.entries.Length > 0) > { > DataTable dataTableaccount = new DataTable(); > dataTableaccount.Columns.AddRange(new DataColumn[] { > new DataColumn("name", typeof(string)), > > new DataColumn("customerId", typeof(string)), > new DataColumn("companyName", typeof(string)), > new DataColumn("currencyCode", typeof(string)), > new DataColumn("dateTimeZone.", typeof(string)), > > }); > > > > > Using this above code i am getting the Error: > > > > Failed to get Accounts. Exception says "[SelectorError.INVALID_FIELD_NAME > @ serviceSelector; trigger:'name', SelectorError.INVALID_FIELD_NAME @ > serviceSelector; trigger:'currencyCode', SelectorError.INVALID_FIELD_NAME @ > serviceSelector; trigger:'dateTimeZone']" > -- -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and discussion group: http://adwordsapi.blogspot.com http://groups.google.com/group/adwords-api =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ You received this message because you are subscribed to the Google Groups "AdWords API Forum" 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/adwords-api?hl=en
