Hi Joe, It could be that there is no site (placement) max CPC set for the ad group, esp if the campaign isn't running on the CONTENT_NETWORK. If you take a look at the SOAP XML you might get a better idea of what is being returned.
Best, - Eric On Oct 12, 1:10 am, Joe <jdvera...@gmail.com> wrote: > Hi Eric, > > I tried to cast: > ManualCPCAdGroupBids test = (ManualCPCAdGroupBids) adGroup.getBids(); > System.out.println ("test" +test.getSiteMaxCpc() > +"test1"+test.getKeywordContentMaxCpc()+"test2"+test.getSiteMaxCpc()); > > It returns to NULL and it seems i tried use the code : > test.getSiteMaxCpc().getAmount, there is null pointer exception. > Therefor the test value is null. I don't understand I tried to output > the System.out.println(adGroup.getBids().getAdGroupBidsType()); // it > displays ManualCPCAdGroupBids , I assume its ManualCPCAdGroupBids but > bid values of ManualCPCAdGroupBids are null. > > Can you please give me example how to get bid values in every adgroup? > I'm still intermediate level these adwords api. > > Thanks, > Joe > > On Oct 11, 8:47 am, AdWords API Advisor <adwordsapiadvi...@google.com> > wrote: > > > > > > > > > Hi Joe, > > > Which part of the code returns null? It seems like you have the basic > > idea, although I think you need to cast adGroup.getBids() to > > ManualCPCAdGroupBids to get access to the fields. > > > Best, > > - Eric Koleda, AdWords API Team > > > On Oct 8, 12:28 am, Joe <jdvera...@gmail.com> wrote: > > > > Hi, > > > > I'm trying to get the bid values like keywordMaxCpc, > > > keywordContentMaxCpc and siteMaxCpc from ManualCPCAdGroupBids. > > > Code: > > > > System.out.println(adGroup.getBids().getAdGroupBidsType()); // it > > > displays ManualCPCAdGroupBids > > > > ManualCPCAdGroupBids test = adGroup.getBids(); > > > System.out.println ("test" +test.getSiteMaxCpc() > > > +"test1"+test.getKeywordContentMaxCpc()+"test2"+test.getSiteMaxCpc()); > > > > Please give me a logic sample on how to get AdgroupsBids type and > > > their bid values from Adgroup list. > > > > Thanks, > > > - Joe -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ 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 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