Hi , 1. I had logged into my MCC account account when i generated the refresh token in my config. 2. The client customer ID that i am using in my code snippet below is for an AdWords account * config.ClientCustomerId = "449-909-2808".ToString().Replace("-", "")*
Thanks and Regards On Tuesday, July 22, 2014 4:32:46 PM UTC+5:30, Chad Ruff wrote: > > Hi , > > I have adwords google api asp.net code > sample googleads-dotnet-lib-master.zip > > I have also generated the OAuth2RefreshToken using the OAuthTokenGenerator > project > > i have made changes to the app.config file > <add key="UserAgent" value="GoogleAdwordsTest"/> > <add key="DeveloperToken" value="DeveloperToken"/> > <add key="ClientCustomerId" value="123-456-7890"/> > <add key="AuthorizationMethod" value="OAuth2" /> > <add key="Email" value="t...@gmail.com"/> > <add key="Password" value="Password"/> > <add key="OAuth2ClientId" value=" > xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx.apps.googleusercontent.com" /> > <add key="OAuth2ClientSecret" value="xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" /> > <add key="OAuth2Mode" value="APPLICATION" /> > > i am running the Google.Api.Adwords.Examples.VB.v201406.GetCampaigns > sample from > > Adwords.Examples.VB Project v201406-->BasicOperations--> GetCampaigns.vb > class > > i have just added these two lines > > Public Sub Run(ByVal user As AdWordsUser) > ' Get the CampaignService. > Dim campaignService As CampaignService = user.GetService( _ > AdWordsService.v201406.CampaignService) > > * Dim config As AdWordsAppConfig = DirectCast(user.Config, > AdWordsAppConfig)* > * config.ClientCustomerId = > "987-654-4321".ToString().Replace("-", "")* > * config.DeveloperToken = "DeveloperToken"* > > Dim selector As New Selector > selector.fields = New String() {"Id", "Name", "Status"} > > ' Set the selector paging. > selector.paging = New Paging > > Dim offset As Integer = 0 > Dim pageSize As Integer = 500 > > Dim page As New CampaignPage > > Try > Do > selector.paging.startIndex = offset > selector.paging.numberResults = pageSize > > ' Get the campaigns. > page = campaignService.get(selector) > > *I am getting this error [AuthorizationError.USER_PERMISSION_DENIED @ ; > trigger:'<null>'] on the above line* > > -- -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and Google+: https://googleadsdeveloper.blogspot.com/ https://plus.google.com/+GoogleAdsDevelopers/posts =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ You received this message because you are subscribed to the Google Groups "AdWords API Forum" group. To post to this group, send email to adwords-api@googlegroups.com To unsubscribe from this group, send email to adwords-api+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/adwords-api?hl=en --- You received this message because you are subscribed to the Google Groups "AdWords API Forum" group. To unsubscribe from this group and stop receiving emails from it, send an email to adwords-api+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.