Customized Report Code Sample

The following code snippet shows how to prepare a request object for a daily keyword performance report on 02/01/2006.

// Construct report request
reportRequest = new KeywordPerformanceReportRequest();
reportRequest.AccountId = 199999;
reportRequest.ReportLanguage = LanguageType.English;
reportRequest.Format = APIResultFileType.CSV;
reportRequest.ReportDateRange = ReportDateRangeType.Customized;
reportRequest.ReportDates = new DateTime[1];
reportRequest.ReportDates[0] = new DateTime(2006, 2, 1);
reportRequest.ReportAggregation = ReportAggregationType.Day;

// Request report
reportId = objReporting.RequestBIReport(apiFlags, reportRequest);

See Also

Reference

Reporting

Concepts

How to Request and Retrieve a Report