Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/csharp-4.0/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C# ReportWebService.Schedule描述日期格式_C#_C# 4.0_Reporting Services - Fatal编程技术网

C# ReportWebService.Schedule描述日期格式

C# ReportWebService.Schedule描述日期格式,c#,c#-4.0,reporting-services,C#,C# 4.0,Reporting Services,我正在查询报告服务计划并获取项目数组。这些项目中有一个描述字段,如下所示: Every 1 hour(s) and 0 minute(s), starting 11/1/2014 at 2:00 AM and ending 3/31/2015 是否有任何选项可以设置此文件的区域性,使其以英国格式返回?i、 e Every 1 hour(s) and 0 minute(s), starting 1/11/2014 at 2:00 AM and ending 31/3/2015 我的代码是:

我正在查询报告服务计划并获取项目数组。这些项目中有一个描述字段,如下所示:

Every 1 hour(s) and 0 minute(s), starting 11/1/2014 at 2:00 AM and ending 3/31/2015
是否有任何选项可以设置此文件的区域性,使其以英国格式返回?i、 e

Every 1 hour(s) and 0 minute(s), starting 1/11/2014 at 2:00 AM and ending 31/3/2015
我的代码是:

           var reportService = new ReportingService2005();
            reportService.Credentials = GetReportCredentials();

            var schedules = reportService.ListSchedules();
            var scheduleViews = schedules.Select(s => new ReportScheduleSearchView { 
                Guid = s.ScheduleID,
                Name = s.Name,
                Description = s.Description,
                State = s.State.ToString(),
            });

报表管理器的语言由浏览器设置(即:工具>Internet选项>语言)定义。也许你可以试试你的申请书


这些
2014年11月1日
2015年3月31日
来自哪里?它们是
string
还是
DateTime
值?如果它们是字符串,您是否尝试先解析它们,然后再格式化?如果它们是日期时间,您是否尝试格式化它们?或者更重要的是,您尝试过什么吗?它们是计划项中的日期时间值。说明是根据这些值自动生成的,但这些值的格式正确(2015年3月31日)
using System.Threading;
using System.Globalization;
// Set the culture
Thread.CurrentThread.CurrentCulture = new CultureInfo("en-GB");
// Set the UI culture
Thread.CurrentThread.CurrentUICulture = new CultureInfo("en-GB");