I have been using V201008 and have started migrating to V201101 and
immediately was stumped on where my AdGroup.bids have gone? What is
the secret to obtaining the bids when using the AdGroupService to
obtain/get an Adgroup. The selector.fields was my first thought and
to add "bids" but it does not show as "Selectable" in
http://code.google.com/apis/adwords/docs/reference/latest/AdGroupService.AdGroup.html
I've doubled checked that the AdGroup w/n the Campaign does in fact
have a dft bid of type ManualCPCAdGroupBids and that the prev version,
V201008, works as designed.
Hopeful I can iron our all the modifications required due to the
Selector forcing one to define the fields one desires when "getting"
data via the web service methods, before the end of life. Never
imagined all the changes and the V201101 release is not backward
compatible.
Here is my code:
<code>
' V201101 - Start
Dim adgroup As GoogleAdGroupAPI.AdGroup = Nothing
adgroup = New GoogleAdGroupAPI.AdGroup()
' Create the selector.
Dim selector As New GoogleAdGroupAPI.Selector
selector.fields = New String() {"Id", "Name", "Status"}
' Create the filters.
Dim predicate As New GoogleAdGroupAPI.Predicate
predicate.field = "CampaignId"
predicate.operator = GoogleAdGroupAPI.PredicateOperator.EQUALS
predicate.operatorSpecified = True
predicate.values = New String() {myCampaignID.ToString}
Try
' Get all AdGroups for specified campaign id passed.
selector.predicates = New GoogleAdGroupAPI.Predicate()
{predicate}
Dim page As GoogleAdGroupAPI.AdGroupPage =
myService.get(selector)
' Display AdGroups.
ix = 0
If page IsNot Nothing AndAlso page.entries IsNot Nothing
Then
If page.entries.Length > 0 Then
For Each adgroup In page.entries
Console.WriteLine("AdGroups with id = '{0}',
name = '{1}' and status = '{2}'" + " was found.", adgroup.id,
adgroup.name, adgroup.status)
MyArray.Add(adgroup)
Next
Else
Console.WriteLine("No adgroups were found.")
End If
End If
Catch ex As Exception
Console.WriteLine("Failed to retrieve adGroup(s).
Exception says ""{0}""", ex.Message)
End Try
</code>
Thanks in advance for any assistance in finding my lost Adgroup.bids
--
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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