[image: 微信截图_2019070816ss2344.png]
runExample code:
 public static void runExample(
            AdWordsServicesInterface adWordsServices, AdWordsSession 
session, String reportFile)
            throws ReportDownloadResponseException, ReportException, 
IOException {
        ReportQuery query =
                new ReportQuery.Builder()
                        .fields(
                              
 
"AdGroupId","AdGroupName","AdGroupStatus","CampaignId","CampaignName","CampaignStatus","CityCriteriaId","Impressions","CountryCriteriaId"
                        )
                        
.from(ReportDefinitionReportType.GEO_PERFORMANCE_REPORT)
                        .during(ReportDefinitionDateRangeType.LAST_7_DAYS)
                        .build();

        ReportingConfiguration reportingConfiguration =
                new ReportingConfiguration.Builder()
                        .skipReportHeader(true)
                        .skipColumnHeader(false)
                        .skipReportSummary(false)
                        .includeZeroImpressions(false)
                        .build();
        session.setReportingConfiguration(reportingConfiguration);

        ReportDownloaderInterface reportDownloader =
                adWordsServices.getUtility(session, 
ReportDownloaderInterface.class);
        ReportDownloadResponse response =
                reportDownloader.downloadReport(query.toString(), 
DownloadFormat.CSV);
        response.saveToFile(reportFile);

        System.out.printf("Report successfully downloaded to: %s%n", 
reportFile);
    }


有谁知道这是为什么?

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads 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 and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/5a30a3ef-fddf-4682-b5f4-f1084c9272fc%40googlegroups.com.

Reply via email to