Hi,

I am facing issue with AD_PERFORMANCE_REPORT download. following is my code 

(user.Config as AdWordsAppConfig).ClientCustomerId = "*************" // 
original id is differ
            ReportDefinition definition = new ReportDefinition();

            definition.reportName = "All time reports";
            definition.reportType = 
ReportDefinitionReportType.AD_PERFORMANCE_REPORT;
            definition.downloadFormat = DownloadFormat.GZIPPED_CSV;
            definition.dateRangeType = 
ReportDefinitionDateRangeType.ALL_TIME;

            // Create selector.
            Selector selector = new Selector();
            selector.fields = new string[] {  "account"
                                            , "clientName"
                                            , "campaign"
                                            , "campaignID"
                                            , "adGroup"
                                            , "adGroupID"
                                            , "adID"
                                            , "adApprovalStatus"
                                            , "adState"
                                            , "ad"
                                            , "descriptionLine1"
                                            , "descriptionLine2"
                                            , "destinationURL"
                                            , "displayURL"
                                            , "avgCPC"
                                            , "avgPosition"
                                            , "clicks"
                                            , "conversions"
                                            , "convRate"
                                            , "cost"
                                            , "costConv"
                                            , "ctr"
                                            , "device"
                                            , "devicePreference"
                                            , "disapprovalReasons"
                                            , "finalURL"
                                            , "impressions"};

            Predicate predicate = new Predicate();
            predicate.field = "Status";
            predicate.@operator = PredicateOperator.IN;
            predicate.values = new string[] { "ENABLED", "PAUSED" };
            selector.predicates = new Predicate[] { predicate };

            definition.selector = selector;
            definition.includeZeroImpressions = true;

            string File_Name = string.Format("EXR-Test-Report-{0}.csv", 
DateTime.Now.ToString("yyyy-MM-dd_HH_mm"));

            string filePath = AppDomain.CurrentDomain.BaseDirectory + 
@"App_Data\" + File_Name;


            try
            {
                ReportUtilities utilities = new ReportUtilities(user, 
"v201409", definition);
                using (ReportResponse response = utilities.GetResponse())
                {
                    response.Save(filePath);
                }
                Console.WriteLine("Report was downloaded to '{0}'.", 
filePath);
            }
            catch (Exception ex)
            {
                throw new System.ApplicationException("Failed to download 
report.", ex);
            }

please check the following issue


<https://lh3.googleusercontent.com/-TvCLkVMB7Y4/VRE2e1saiLI/AAAAAAAAAcM/iZnnKapsEYY/s1600/2015-03-24_1527.png>







-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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.
Visit this group at http://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/a7513426-1c61-4967-b774-4ca0b2925084%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to