图片 25

基于DEV控件库的webservice打印.repx模板

在winfrom的环境下 XtraReport 是可以直接调用 Print() 打印的。

DevExpress.XtraEditors.Controls
此控件包中包含的控件最多,包括文本框,下拉列表,按钮,等等
DevExpress.XtraGrid 网格
DevExpress.XtraBars 菜单栏 和 工具栏
DevExpress.XtraNavBar 导航条
DevExpress.XtraPrinting 报表打印相关
DevExpress.XtraReports 报表
DevExpress.XtraTreeList 树

DXMap for WPF

  • 自定义地图颜色的MapColorizer现在需要重载
    MapColorizer.GetItemColor(以前是MapColorizer.ColorizeElement)

我们开发程序的时候,经常会碰到一些报表,如果是Winform的报表,一般可以采用DevExpress控件组的XtraReport,或者微软的RDLC报表,当然还有一些其他的,在此不再赘述。由于本人在Winform开发中经常使用到一些报表,有时候使用XtraReport报表,有时候也使用RDLC报表,因此本篇主要介绍这两种不同类型报表的使用,以及对比它们的差异性,以便我们更好的掌握了解。

DevExpress.XtraPrinting.v10.1

1.先将该类生成的Dll导入工程中
,也可以不生成dll,把该类放到项目中就行了。
2.在你的From_Load()或者program.cs中实例化该类即可

DXControls for WPF

IDialogService.ShowDialog 方法的定义方式变化,之前的定义是:

1
MessageBoxResult ShowDialog(MessageBoxButton button, string title, string documentType, object parameter, object parentViewModel, bool useParameterAsViewModel);

新的定义方式:

1
UICommand ShowDialog(IList<UICommand> dialogCommands, MessageBoxButton? dialogButtons, string title, string documentType, object viewModel, object parameter, object parentViewModel);

建议不直接调用IDialogService.ShowDialog,用DialogServiceExtensions类提供的扩展方法代替。下面是这个类以前提供的方法定义:

1
2
3
public static MessageBoxResult ShowDialog(this IDialogService service, MessageBoxButton button, string title, object viewModel)
          public static MessageBoxResult ShowDialog(this IDialogService service, MessageBoxButton button, string title, string documentType, object viewModel)
          public static MessageBoxResult ShowDialog(this IDialogService service, MessageBoxButton button, string title, string documentType, object parameter, object parentViewModel)

当前新定义:

1
2
3
4
5
6
public static MessageBoxResult ShowDialog(this IDialogService service, MessageBoxButton dialogButtons, string title, object viewModel)
          public static MessageBoxResult ShowDialog(this IDialogService service, MessageBoxButton dialogButtons, string title, string documentType, object viewModel)
          public static MessageBoxResult ShowDialog(this IDialogService service, MessageBoxButton dialogButtons, string title, string documentType, object parameter, object parentViewModel)
          public static UICommand ShowDialog(this IDialogService service, IList<UICommand> dialogCommands, string title, object viewModel)
          public static UICommand ShowDialog(this IDialogService service, IList<UICommand> dialogCommands, string title, string documentType, object viewModel)
          public static UICommand ShowDialog(this IDialogService service, IList<UICommand> dialogCommands, string title, string documentType, object parameter, object parentViewModel)

IDocumentManagerService 提供的CreateDocument方法,以前的定义方式:

1
IDocument CreateDocument(string documentType, object parameter = null, object parentViewModel = null, bool useParameterAsViewModel = false);

新的定义方式:

1
IDocument CreateDocument(string documentType, object viewModel, object parameter, object parentViewModel);

DocumentManagerServiceExtensions类包含一个扩展
CreateDocument,以前的定义方式:

1
public static IDocument CreateDocument(this IDocumentManagerService service, object viewModel)

在13.1.7,定义方式改为:

1
2
3
4
public static IDocument CreateDocument(this IDocumentManagerService service, object viewModel)
          public static IDocument CreateDocument(this IDocumentManagerService service, string documentType, object viewModel)
          public static IDocument CreateDocument(this IDocumentManagerService service, string documentType, object parameter, object parentViewModel)
          public static IDocument CreateDocument(this IDocumentManagerService service, string documentType, object parameter, object parentViewModel, bool useParameterAsViewModel)

 4)特殊字段的处理

在报表的设计过程中,我们一般会碰到各种不同的字段,它不是简单的文本信息,可能是日期,也可以是统计值,计算值等。

图片 1

基于DEV控件库的webservice打印.repx模板。打印时间,只需要增加一个XRPageInfo,然后设置里面的值就可以了,这个有点类似RDLC的参数值。

图片 2

从上面我们可以看到有很多项目可以选的,除了有时间,还有记录数、总记录数、用户名、总数等等。

记录数的统计设计如下所示,主要是通过千制的方式显示,调用Count函数处理。

图片 3

同样,总公里数,是统计整个报表里面记录的公里数操作,调用SUM函数处理,它的设计界面如下。

 图片 4

设计好Xtra报表后,我们就可以程序里面,直接调用进行加载处理即可,代码如下所示。

        private void PrintReport()
        {
            string where = GetConditionSql();
            List<CarApplyInfo> list = BLLFactory<CarApply>.Instance.Find(where);

            FrmHistoryReport report = new FrmHistoryReport();
            report.DataSource = list;

            ReportPrintTool tool = new ReportPrintTool(report);
            tool.ShowPreview();
        }

我们主要获取数据源,并绑定数据源到对应的报表组件上,然后调用ReportPrintTool
进行展现即可,代码非常简洁,只是设计过程麻烦一些。

 

所以改用 ReportPrintTool 进行打印。

使用方法:

Map for Windows 8 XAML

  • 自定义地图颜色的MapColorizer现在需要重载
    MapColorizer.GetItemColor(以前是MapColorizer.ColorizeElement)

2)创建新报表

为了实现这个报表模块,我们先使用VS的工具创建一个报表组件对象。

图片 5

 

在使用前,我们需要设置好报表组件的各个显示模块,报表报表上下空间部分(TopMargin/BottomMargin),这两个部分用来调整上下的边线的;

然后每个报表有头部内容和底部内容的区分,ReportHeader一般用来放置表格头部字段显示的,明细的内容包括展示列表的明细信息,大致调整如下所示。

图片 6

图片 7

 

但是在webservice的环境下直接调用会出现错误 The method or operation is not supported.

DevExpress
第三方控件汉化代码和使用方法,Dev测试版本为9.3.4,可适用于多个版本。

DevExpress下的.NET界面组件 DXperience Universal Suite
最新发布13.1.7版,多个属性的定义方式发生变化,另外还有大量的bug修复。使用DevExpress朋友一定要注意以下更新:

1)报表界面展示

在我的派车管理系统里面,我需要根据数据库的记录,把相关的派车历史信息做成一个报表统计的模块,需要列出报表的明细(派车明细)和统计值(记录数、公里数),这种类型的报表是很多情况下需要碰到的。

我需要实现一个基于XtraReport报表技术实现的功能界面,如下面图示所示。

 图片 8

这里面涉及的字段,包括字符型、日期型,数值型、枚举类型等,还有统计值、打印时间(参数),因此也算一个比较完整的报表展示了。

 

打印为webservice部署的服务器所连接的打印机。

   1: using System;   

   2: using DevExpress.XtraEditors.Controls;   

   3: using DevExpress.XtraGrid.Localization;

   4: using DevExpress.XtraBars.Customization;

   5: using DevExpress.XtraBars.Localization;

   6: using DevExpress.XtraNavBar;

   7: using DevExpress.XtraPrinting.Localization;

   8: using DevExpress.XtraReports.Localization;

   9: using DevExpress.XtraTreeList.Localization;

  10: using DevExpress.XtraVerticalGrid.Localization;

  11:  

  12:  

  13: namespace ChineseLanguage

  14: {

  15:     public class Chinese

  16:     {

  17:         public Chinese()

  18:         {

  19:             Localizer.Active = new XtraEditors_CN();

  20:             GridLocalizer.Active = new XtraGrid_CN();

  21:             BarLocalizer.Active = new XtraBar_CN();

  22:                BarLocalizer.Active.Customization = new XtraBarsCustomizationLocalization_CN();

  23:                NavBarLocalizer.Active = new XtraNavBar_CN();

  24:             PreviewLocalizer.Active = new XtraPrinting_CN();

  25:             ReportLocalizer.Active = new XtraReports_CN();

  26:             TreeListLocalizer.Active = new XtraTreeList_CN();

  27:                VGridLocalizer.Active = new XtraVerticalGrid_CN();

  28:         }

  29:     }

  30:  

  31:  

  32:     public class XtraEditors_CN :Localizer

  33:     {

  34:         public XtraEditors_CN()

  35:         {

  36:             //

  37:             // TODO: 在此处添加构造函数逻辑

  38:             //

  39:         }

  40:         public override string Language

  41:         {

  42:             get

  43:             {

  44:                 return "简体中文";

  45:             }

  46:         }

  47:  

  48:         public override string GetLocalizedString(StringId id)   

  49:         {   

  50:             switch(id)     

  51:             { 

  52:                 case StringId.TextEditMenuCopy:return "复制(&C)";

  53:                 case StringId.TextEditMenuCut:return "剪切(&T)";

  54:                 case StringId.TextEditMenuDelete:return "删除(&D)";

  55:                 case StringId.TextEditMenuPaste:return "粘贴(&P)";

  56:                 case StringId.TextEditMenuSelectAll:return "全选(&A)";

  57:                 case StringId.TextEditMenuUndo:return "撤消(&U)";

  58:                 case StringId.UnknownPictureFormat:return "未知图片格式";

  59:                 case StringId.DateEditToday:return "今天";

  60:                 case StringId.DateEditClear:return "清空";

  61:                 case StringId.DataEmpty:return "无图像";

  62:                 case StringId.ColorTabWeb:return "网页";

  63:                 case StringId.ColorTabSystem:return "系统";

  64:                 case StringId.ColorTabCustom:return "自定义";

  65:                 case StringId.CheckUnchecked:return "未选择";

  66:                 case StringId.CheckIndeterminate:return "不确定";

  67:                 case StringId.CheckChecked:return "已选择";

  68:                 case StringId.CaptionError:return "标题错误";

  69:                 case StringId.Cancel:return "取消";

  70:                 case StringId.CalcError:return "计算错误";

  71:                 case StringId.CalcButtonBack:return base.GetLocalizedString(id);

  72:                 case StringId.CalcButtonC:return base.GetLocalizedString(id);

  73:                 case StringId.CalcButtonCE:return base.GetLocalizedString(id);;

  74:                 case StringId.CalcButtonMC:return base.GetLocalizedString(id);

  75:                 case StringId.CalcButtonMR:return base.GetLocalizedString(id);

  76:                 case StringId.CalcButtonMS:return base.GetLocalizedString(id);

  77:                 case StringId.CalcButtonMx:return base.GetLocalizedString(id);

  78:                 case StringId.CalcButtonSqrt:return base.GetLocalizedString(id);

  79:                 case StringId.OK:return "确定";

  80:                 case StringId.PictureEditMenuCopy:return "复制(&C)";

  81:                 case StringId.PictureEditMenuCut:return "剪切(&T)";

  82:                 case StringId.PictureEditMenuDelete:return "删除(&D)";

  83:                 case StringId.PictureEditMenuLoad:return "加载(&L)";

  84:                 case StringId.PictureEditMenuPaste:return "粘贴(&P)";

  85:                 case StringId.PictureEditMenuSave:return "保存(&S)";

  86:                 case StringId.PictureEditOpenFileError:return "错误图片格式";

  87:                 case StringId.PictureEditOpenFileErrorCaption:return "打开错误";

  88:                 case StringId.PictureEditOpenFileFilter:return "位图文件(*.bmp)|*.bmp|GIF动画 (*.gif)|*.gif|JPEG(*.jpg;*.jpeg)|*.jpg;*.jpeg|ICO(*.ico)|*.ico|所有图片文件|*.bmp;*.gif;*.jpeg;*.jpg;*.ico|所有文件(*.*)|*.*";

  89:                 case StringId.PictureEditOpenFileTitle:return "打开";

  90:                 case StringId.PictureEditSaveFileFilter:return "位图文件(*.bmp)|*.bmp|GIF动画(*.gif)|*.gif|JPEG(*.jpg)|*.jpg";

  91:                 case StringId.PictureEditSaveFileTitle:return "保存为";

  92:                 case StringId.TabHeaderButtonClose:return "关闭";

  93:                 case StringId.TabHeaderButtonNext:return "下一页";

  94:                 case StringId.TabHeaderButtonPrev:return "上一页";

  95:                 case StringId.XtraMessageBoxAbortButtonText:return "中断(&A)";

  96:                 case StringId.XtraMessageBoxCancelButtonText:return "取消(&C)";

  97:                 case StringId.XtraMessageBoxIgnoreButtonText:return "忽略(&I)";

  98:                 case StringId.XtraMessageBoxNoButtonText:return "否(&N)";

  99:                 case StringId.XtraMessageBoxOkButtonText:return "确定(&O)";

 100:                 case StringId.XtraMessageBoxRetryButtonText:return "重试(&R)";

 101:                 case StringId.XtraMessageBoxYesButtonText:return "是(&Y)";

 102:                 case StringId.ImagePopupEmpty:return "(空)";

 103:                 case StringId.ImagePopupPicture:return "(图片)";

 104:                 case StringId.InvalidValueText:return "无效的值";

 105:                 case StringId.LookUpEditValueIsNull:return "[无数据]";

 106:                 case StringId.LookUpInvalidEditValueType:return "无效的数据类型";

 107:                 case StringId.MaskBoxValidateError:return "输入数值不完整. 是否须要修改? 是 - 回到编辑模式以修改数值. 否 - 保持原来数值. 取消 - 回复原来数值. ";

 108:                 case StringId.NavigatorAppendButtonHint:return "添加";

 109:                 case StringId.NavigatorCancelEditButtonHint:return "取消编辑";

 110:                 case StringId.NavigatorEditButtonHint:return "编辑";

 111:                 case StringId.NavigatorEndEditButtonHint:return "结束编辑";

 112:                 case StringId.NavigatorFirstButtonHint:return "第一条";

 113:                 case StringId.NavigatorLastButtonHint:return "最后一条";

 114:                 case StringId.NavigatorNextButtonHint:return "下一条";

 115:                 case StringId.NavigatorNextPageButtonHint:return "下一页";

 116:                 case StringId.NavigatorPreviousButtonHint:return "上一条";

 117:                 case StringId.NavigatorPreviousPageButtonHint:return "上一页";

 118:                 case StringId.NavigatorRemoveButtonHint:return "删除";

 119:                 case StringId.NavigatorTextStringFormat:return "记录{0}/{1}";

 120:                 case StringId.None:return "";

 121:                 case StringId.NotValidArrayLength:return "无效的数组长度.";

 122:             }

 123:             return base.GetLocalizedString(id);

 124:         }

 125:  

 126:     }

 127:     

 128:     

 129:     public class XtraGrid_CN :GridLocalizer 

 130:     {

 131:         public override string Language

 132:         {

 133:             get

 134:             {

 135:                 return "简体中文";

 136:             }

 137:         }

 138:         

 139:         public override string GetLocalizedString(GridStringId id)

 140:         {

 141:             switch(id)

 142:             {

 143:                 case GridStringId.CardViewNewCard:return "新卡片";

 144:                 case GridStringId.CardViewQuickCustomizationButton:return "自定义格式";

 145:                 case GridStringId.CardViewQuickCustomizationButtonFilter:return "筛选";

 146:                 case GridStringId.CardViewQuickCustomizationButtonSort:return "排序";    

 147:                 case GridStringId.ColumnViewExceptionMessage:return "是否确定修改?";

 148:                 case GridStringId.CustomFilterDialog2FieldCheck:return "字段";

 149:                 case GridStringId.CustomFilterDialogCancelButton:return "取消";

 150:                 case GridStringId.CustomFilterDialogCaption:return "条件为:";

 151:                 case GridStringId.CustomFilterDialogConditionBlanks:return "空值";

 152:                 case GridStringId.CustomFilterDialogConditionEQU:return "等于=";

 153:                 case GridStringId.CustomFilterDialogConditionGT:return "大于>";

 154:                 case GridStringId.CustomFilterDialogConditionGTE:return "大于或等于>=";

 155:                 case GridStringId.CustomFilterDialogConditionLike:return "包含";

 156:                 case GridStringId.CustomFilterDialogConditionLT:return "小于<";

 157:                 case GridStringId.CustomFilterDialogConditionLTE:return "小于或等于>=";

 158:                 case GridStringId.CustomFilterDialogConditionNEQ:return "不等于<>";

 159:                 case GridStringId.CustomFilterDialogConditionNonBlanks:return "非空值";

 160:                 case GridStringId.CustomFilterDialogConditionNotLike:return "不包含";

 161:                 case GridStringId.CustomFilterDialogFormCaption:return "清除筛选条件(&L)";

 162:                 case GridStringId.CustomFilterDialogOkButton:return "确定(&O)";

 163:                 case GridStringId.CustomFilterDialogRadioAnd:return "和(&A)";

 164:                 case GridStringId.CustomFilterDialogRadioOr:return "或者(&O)";

 165:                 case GridStringId.CustomizationBands:return "分区";

 166:                 case GridStringId.CustomizationCaption:return "自定义显示字段";

 167:                 case GridStringId.CustomizationColumns:return "列";

 168:                 case GridStringId.FileIsNotFoundError:return "文件{0}没找到!";

 169:                 case GridStringId.GridGroupPanelText:return "拖曳一列页眉在此进行排序";

 170:                 case GridStringId.GridNewRowText:return "单击这里新增一行";

 171:                 case GridStringId.GridOutlookIntervals:return "一个月以上;上个月;三周前;两周前;上周;;;;;;;;昨天;今天;明天; ;;;;;;;下周;两周后;三周后;下个月;一个月之后;";

 172:                 case GridStringId.MenuColumnBestFit:return "自动调整字段宽度";

 173:                 case GridStringId.MenuColumnBestFitAllColumns:return "自动调整所有字段宽度";

 174:                 case GridStringId.MenuColumnClearFilter:return "清除筛选条件";

 175:                 case GridStringId.MenuColumnColumnCustomization:return "显示/隐藏字段";

 176:                 case GridStringId.MenuColumnFilter:return "筛选";

 177:                 case GridStringId.MenuColumnGroup:return "按此列分组";

 178:                 case GridStringId.MenuColumnGroupBox:return "分组区";

 179:                 case GridStringId.MenuColumnSortAscending:return "升序排序";

 180:                 case GridStringId.MenuColumnSortDescending:return "降序排序";

 181:                 case GridStringId.MenuColumnUnGroup:return "取消分组";

 182:                 case GridStringId.MenuFooterAverage:return "平均";

 183:                 case GridStringId.MenuFooterAverageFormat:return "平均={0:#.##}";

 184:                 case GridStringId.MenuFooterCount:return "计数";

 185:                 case GridStringId.MenuFooterCountFormat:return "{0}";

 186:                 case GridStringId.MenuFooterMax:return "最大值";

 187:                 case GridStringId.MenuFooterMaxFormat:return "最大值={0}";

 188:                 case GridStringId.MenuFooterMin:return "最小";

 189:                 case GridStringId.MenuFooterMinFormat:return "最小值={0}";

 190:                 case GridStringId.MenuFooterNone:return "没有";

 191:                 case GridStringId.MenuFooterSum:return "合计";

 192:                 case GridStringId.MenuFooterSumFormat:return "求和={0:#.##}";

 193:                 case GridStringId.MenuGroupPanelClearGrouping:return "取消所有分组";

 194:                 case GridStringId.MenuGroupPanelFullCollapse:return "收缩全部分组";

 195:                 case GridStringId.MenuGroupPanelFullExpand:return "展开全部分组";

 196:                 case GridStringId.PopupFilterAll:return "(所有)";

 197:                 case GridStringId.PopupFilterBlanks:return "(空值)";

 198:                 case GridStringId.PopupFilterCustom:return "(自定义)";

 199:                 case GridStringId.PopupFilterNonBlanks:return "(非空值)";

 200:                 case GridStringId.PrintDesignerBandedView:return "打印设置(区域模式)";

 201:                 case GridStringId.PrintDesignerBandHeader:return "区标题";

 202:                 case GridStringId.PrintDesignerCardView:return "打印设置(卡片模式)";

 203:                 case GridStringId.PrintDesignerDescription:return "为当前视图设置不同的打印选项.";

 204:                 case GridStringId.PrintDesignerGridView:return "打印设置(表格模式)";

 205:                 case GridStringId.WindowErrorCaption:return "错误";

 206:             }

 207:             return base.GetLocalizedString(id);

 208:         }

 209:     }

 210:  

 211:     

 212:     public class XtraBar_CN :BarLocalizer

 213:     {

 214:         public override string Language

 215:         {

 216:             get

 217:             {

 218:                 return "简体中文";

 219:             }

 220:         }

 221:  

 222:         public override string GetLocalizedString(BarString id)

 223:         {

 224:             switch(id)

 225:             {

 226:                 case BarString.AddOrRemove:return "新增或删除按钮(&A)";

 227:                 case BarString.CustomizeButton:return "自定义(&C)";

 228:                 case BarString.CustomizeWindowCaption:return "自定义";

 229:                 case BarString.MenuAnimationFade:return "减弱";

 230:                 case BarString.MenuAnimationNone:return "空";

 231:                 case BarString.MenuAnimationRandom:return "任意";

 232:                 case BarString.MenuAnimationSlide:return "滑动";

 233:                 case BarString.MenuAnimationSystem:return "(系统默认值)";

 234:                 case BarString.MenuAnimationUnfold:return  "展开";

 235:                 case BarString.NewToolbarCaption:return "新建工具栏";

 236:                 case BarString.None:return "";

 237:                 case BarString.RenameToolbarCaption:return "重新命名";

 238:                 case BarString.ResetBar:return "是否确实要重置对 '{0}' 工具栏所作的修改?";

 239:                 case BarString.ResetBarCaption:return "自定义";

 240:                 case BarString.ResetButton:return "重设工具栏(&R)";

 241:                 case BarString.ToolBarMenu:return "重设(&R)$删除(&D)$!命名(&N)$!标准(&L)$总使用文字(&T)$在菜单中只用文字(&O)$图像与文本(&A)$!开始一组(&G)$常用的(&M)";

 242:                 case BarString.ToolbarNameCaption:return "工具栏名称(&T):";

 243:  

 244:             }

 245:             return base.GetLocalizedString(id);

 246:         }

 247:     }

 248:  

 249:  

 250:     public class XtraBarsCustomizationLocalization_CN : CustomizationControl

 251:     {

 252:         private System.ComponentModel.Container components = null;

 253:  

 254:         public XtraBarsCustomizationLocalization_CN()

 255:         {

 256:             // This call is required by the Windows.Forms Form Designer.

 257:             InitializeComponent();

 258:  

 259:             // TODO: Add any initialization after the InitForm call

 260:  

 261:         }

 262:  

 263:         protected override void Dispose(bool disposing)

 264:         {

 265:             if (disposing)

 266:             {

 267:                 if (components != null)

 268:                 {

 269:                     components.Dispose();

 270:                 }

 271:             }

 272:             base.Dispose(disposing);

 273:         }

 274:  

 275:         #region Component Designer generated code

 276:         /// <summary> 

 277:         /// Required method for Designer support - do not modify 

 278:         /// the contents of this method with the code editor.

 279:         /// </summary>

 280:         private void InitializeComponent()

 281:         {

 282:             this.tpOptions.SuspendLayout();

 283:             this.tpCommands.SuspendLayout();

 284:             this.tpToolbars.SuspendLayout();

 285:             ((System.ComponentModel.ISupportInitialize)(this.toolBarsList)).BeginInit();

 286:             ((System.ComponentModel.ISupportInitialize)(this.lbCommands)).BeginInit();

 287:             ((System.ComponentModel.ISupportInitialize)(this.lbCategories)).BeginInit();

 288:             ((System.ComponentModel.ISupportInitialize)(this.cbOptionsShowFullMenus.Properties)).BeginInit();

 289:             ((System.ComponentModel.ISupportInitialize)(this.cbOptions_showFullMenusAfterDelay.Properties)).BeginInit();

 290:             ((System.ComponentModel.ISupportInitialize)(this.cbOptions_showTips.Properties)).BeginInit();

 291:             ((System.ComponentModel.ISupportInitialize)(this.cbOptions_ShowShortcutInTips.Properties)).BeginInit();

 292:             ((System.ComponentModel.ISupportInitialize)(this.tabControl)).BeginInit();

 293:             this.tabControl.SuspendLayout();

 294:             ((System.ComponentModel.ISupportInitialize)(this.tbNBDlgName.Properties)).BeginInit();

 295:             this.pnlNBDlg.SuspendLayout();

 296:             ((System.ComponentModel.ISupportInitialize)(this.cbOptions_largeIcons.Properties)).BeginInit();

 297:             ((System.ComponentModel.ISupportInitialize)(this.cbOptions_MenuAnimation.Properties)).BeginInit();

 298:             this.SuspendLayout();

 299:             

 300:  

 301:             this.btClose.Text = "关闭";

 302:             this.btResetBar.Text = "重新设置(&R)";

 303:             this.btRenameBar.Text = "重命名(&E)";

 304:             this.btNewBar.Text = "新建(&N)";

 305:             this.btDeleteBar.Text = "删除(&D)";

 306:             this.btOptions_Reset.Text = "重置惯用数据(&R)";

 307:             this.btNBDlgCancel.Text = "取消";

 308:             this.btNBDlgOk.Text = "确定";

 309:             this.tpOptions.Size = new System.Drawing.Size(354, 246);

 310:             this.tpOptions.Text = "选项(&O)";

 311:             this.tpCommands.Text = "命令(&C)";

 312:             this.tpToolbars.Text = "工具栏(&B)";            

 313:             this.cbOptionsShowFullMenus.Properties.Caption = "始终显示整个菜单(&N)";

 314:             this.cbOptions_showFullMenusAfterDelay.Properties.Caption = "鼠标指针短暂停留后显示完整菜单(&U)";

 315:             this.cbOptions_largeIcons.Properties.Caption = "大图标(&L)";

 316:             this.cbOptions_showTips.Properties.Caption = "显示关于工具栏屏幕提示(&T)";

 317:             this.cbOptions_ShowShortcutInTips.Properties.Caption = "在屏幕提示中显示快捷键(&H)";

 318:             this.lbDescCaption.Text = "详细说明";

 319:             this.lbOptions_Other.Text = "其它";

 320:             this.lbOptions_PCaption.Text = "个性化菜单和工具栏";

 321:             this.lbCategoriesCaption.Text = "类别:";

 322:             this.lbCommandsCaption.Text = "命令:";

 323:             this.lbToolbarCaption.Text = "工具栏:";

 324:             this.lbOptions_MenuAnimation.Text = "菜单动画设置(&M):";

 325:             this.lbNBDlgCaption.Text = "工具栏名称(&T)";

 326:             this.lbCommands.Appearance.BackColor = System.Drawing.SystemColors.Window;

 327:             this.lbCommands.Appearance.Options.UseBackColor = true;

 328:             this.Name = "XtraBarsCustomizationLocalization_CN";

 329:             this.tpOptions.ResumeLayout(false);

 330:             this.tpCommands.ResumeLayout(false);

 331:             this.tpToolbars.ResumeLayout(false);

 332:             ((System.ComponentModel.ISupportInitialize)(this.toolBarsList)).EndInit();

 333:             ((System.ComponentModel.ISupportInitialize)(this.lbCommands)).EndInit();

 334:             ((System.ComponentModel.ISupportInitialize)(this.lbCategories)).EndInit();

 335:             ((System.ComponentModel.ISupportInitialize)(this.cbOptionsShowFullMenus.Properties)).EndInit();

 336:             ((System.ComponentModel.ISupportInitialize)(this.cbOptions_showFullMenusAfterDelay.Properties)).EndInit();

 337:             ((System.ComponentModel.ISupportInitialize)(this.cbOptions_showTips.Properties)).EndInit();

 338:             ((System.ComponentModel.ISupportInitialize)(this.cbOptions_ShowShortcutInTips.Properties)).EndInit();

 339:             ((System.ComponentModel.ISupportInitialize)(this.tabControl)).EndInit();

 340:             this.tabControl.ResumeLayout(false);

 341:             ((System.ComponentModel.ISupportInitialize)(this.tbNBDlgName.Properties)).EndInit();

 342:             this.pnlNBDlg.ResumeLayout(false);

 343:             ((System.ComponentModel.ISupportInitialize)(this.cbOptions_largeIcons.Properties)).EndInit();

 344:             ((System.ComponentModel.ISupportInitialize)(this.cbOptions_MenuAnimation.Properties)).EndInit();

 345:             this.ResumeLayout(false);

 346:  

 347:         }

 348:         #endregion

 349:     }

 350:  

 351:  

 352:     public class XtraNavBar_CN :NavBarLocalizer

 353:     {

 354:         public override string Language

 355:         {

 356:             get

 357:             {

 358:                 return "简体中文";

 359:             }

 360:         }

 361:         

 362:         public override string GetLocalizedString(NavBarStringId id)

 363:         {

 364:             switch(id)

 365:             {

 366:                 case NavBarStringId.NavPaneChevronHint:return "配置按钮";

 367:                 case NavBarStringId.NavPaneMenuAddRemoveButtons:return "添加或删除按钮(&A)";

 368:                 case NavBarStringId.NavPaneMenuShowFewerButtons:return "显示较少的按钮(&F)";

 369:                 case NavBarStringId.NavPaneMenuShowMoreButtons:return "显示更多的按钮(&M)";

 370:             }

 371:             return base.GetLocalizedString(id);

 372:         }

 373:     }

 374:  

 375:  

 376:     public class XtraPrinting_CN :PreviewLocalizer

 377:     {

 378:         public override string Language

 379:         {

 380:             get

 381:             {

 382:                 return "简体中文";

 383:             }

 384:         }

 385:  

 386:         public override string GetLocalizedString(PreviewStringId id)

 387:         {

 388:             switch(id)

 389:             {

 390:                 case PreviewStringId.Button_Apply:return "应用";

 391:                 case PreviewStringId.Button_Cancel:return "取消";

 392:                 case PreviewStringId.Button_Help:return "帮助";

 393:                 case PreviewStringId.Button_Ok:return "确定";

 394:                 case PreviewStringId.EMail_From:return "From";

 395:                 case PreviewStringId.Margin_BottomMargin:return "下边界";

 396:                 case PreviewStringId.Margin_Inch:return "英寸";

 397:                 case PreviewStringId.Margin_LeftMargin:return "左边界";

 398:                 case PreviewStringId.Margin_Millimeter:return "毫米";

 399:                 case PreviewStringId.Margin_RightMargin:return "右边界";

 400:                 case PreviewStringId.Margin_TopMargin:return "上边界";

 401:                 case PreviewStringId.MenuItem_BackgrColor:return "颜色(&C)";

 402:                 case PreviewStringId.MenuItem_Background:return "背景(&B)";

 403:                 case PreviewStringId.MenuItem_CsvDocument:return "CSV文件";

 404:                 case PreviewStringId.MenuItem_Exit:return "退出(&X)";

 405:                 case PreviewStringId.MenuItem_Export:return "导出(&E)";

 406:                 case PreviewStringId.MenuItem_File: return "文件(&F)";

 407:                 case PreviewStringId.MenuItem_GraphicDocument:return "图片文件";

 408:                 case PreviewStringId.MenuItem_HtmDocument:return "HTML文件";

 409:                 case PreviewStringId.MenuItem_MhtDocument:return "MHT文件";

 410:                 case PreviewStringId.MenuItem_PageSetup:return "页面设置(&U)";

 411:                 case PreviewStringId.MenuItem_PdfDocument:return "PDF文件";

 412:                 case PreviewStringId.MenuItem_Print:return "打印(&P)";

 413:                 case PreviewStringId.MenuItem_PrintDirect:return "直接打印(&R)";

 414:                 case PreviewStringId.MenuItem_RtfDocument:return "RTF文件";

 415:                 case PreviewStringId.MenuItem_Send:return "发送(&D)";

 416:                 case PreviewStringId.MenuItem_TxtDocument:return "TXT文件";

 417:                 case PreviewStringId.MenuItem_View:return "视图(&V)";

 418:                 case PreviewStringId.MenuItem_ViewStatusbar:return "状态栏(&S)";

 419:                 case PreviewStringId.MenuItem_ViewToolbar:return "工具栏(&T)";

 420:                 case PreviewStringId.MenuItem_Watermark:return "水印(&W)";

 421:                 case PreviewStringId.MenuItem_XlsDocument:return "XLS文件";

 422:                 case PreviewStringId.MPForm_Lbl_Pages:return "页";

 423:                 case PreviewStringId.Msg_CreatingDocument:return "正在生成文件";

 424:                 case PreviewStringId.Msg_CustomDrawWarning:return "警告!";

 425:                 case PreviewStringId.Msg_EmptyDocument:return "此文件没有页面.";

 426:                 case PreviewStringId.Msg_FontInvalidNumber:return "字体大小不能为0或负数";

 427:                 case PreviewStringId.Msg_IncorrectPageRange:return "设置的页边界不正确";

 428:                 case PreviewStringId.Msg_NeedPrinter:return "没有安装打印机.";

 429:                 case PreviewStringId.Msg_NotSupportedFont:return "这种字体不被支持";

 430:                 case PreviewStringId.Msg_PageMarginsWarning:return "一个或以上的边界超出了打印范围.是否继续?";

 431:                 case PreviewStringId.Msg_WrongPageSettings:return "打印机不支持所选的纸张大小. 是否继续打印?";

 432:                 case PreviewStringId.Msg_WrongPrinter:return "无效的打印机名称.请检查打印机的设置是否正确.";

 433:                 case PreviewStringId.PageInfo_PageDate:return "[Date Printed]";

 434:                 case PreviewStringId.PageInfo_PageNumber:return "[Page #]";

 435:                 case PreviewStringId.PageInfo_PageNumberOfTotal:return "[Page # of Pages #]";

 436:                 case PreviewStringId.PageInfo_PageTime:return "[Time Printed]";

 437:                 case PreviewStringId.PageInfo_PageUserName:return "[User Name]";

 438:                 case PreviewStringId.PreviewForm_Caption:return "预览";

 439:                 case PreviewStringId.SaveDlg_FilterBmp:return "BMP Bitmap Format";

 440:                 case PreviewStringId.SaveDlg_FilterCsv:return "CSV文件";

 441:                 case PreviewStringId.SaveDlg_FilterGif:return "GIF Graphics Interchange Format";

 442:                 case PreviewStringId.SaveDlg_FilterHtm:return "HTML文件";

 443:                 case PreviewStringId.SaveDlg_FilterJpeg:return "JPEG File Interchange Format";

 444:                 case PreviewStringId.SaveDlg_FilterMht:return "MHT文件";

 445:                 case PreviewStringId.SaveDlg_FilterPdf:return "PDF文件";

 446:                 case PreviewStringId.SaveDlg_FilterPng:return "PNG Portable Network Graphics Format";

 447:                 case PreviewStringId.SaveDlg_FilterRtf:return "RTF文件";

 448:                 case PreviewStringId.SaveDlg_FilterTiff:return "TIFF Tag Image File Format";

 449:                 case PreviewStringId.SaveDlg_FilterTxt:return "TXT文件";

 450:                 case PreviewStringId.SaveDlg_FilterWmf:return "WMF Windows Metafile";

 451:                 case PreviewStringId.SaveDlg_FilterXls:return "Excel文件";

 452:                 case PreviewStringId.SaveDlg_Title:return "另存为";

 453:                 case PreviewStringId.SB_CurrentPageNo:return "目前页码:";

 454:                 case PreviewStringId.SB_PageInfo:return "{0}/{1}";

 455:                 case PreviewStringId.SB_PageNone:return "无";

 456:                 case PreviewStringId.SB_TotalPageNo:return "总页码:";

 457:                 case PreviewStringId.SB_ZoomFactor:return "缩放系数:";

 458:                 case PreviewStringId.ScrollingInfo_Page:return "页";

 459:                 case PreviewStringId.TB_TTip_Backgr:return "背景色";

 460:                 case PreviewStringId.TB_TTip_Close:return "退出";

 461:                 case PreviewStringId.TB_TTip_Customize:return "自定义";

 462:                 case PreviewStringId.TB_TTip_EditPageHF:return "页眉页脚";

 463:                 case PreviewStringId.TB_TTip_Export:return "导出文件";

 464:                 case PreviewStringId.TB_TTip_FirstPage:return "首页";

 465:                 case PreviewStringId.TB_TTip_HandTool:return "手掌工具";

 466:                 case PreviewStringId.TB_TTip_LastPage:return "尾页";

 467:                 case PreviewStringId.TB_TTip_Magnifier:return "放大/缩小";

 468:                 case PreviewStringId.TB_TTip_Map:return "文档视图";

 469:                 case PreviewStringId.TB_TTip_MultiplePages:return "多页";

 470:                 case PreviewStringId.TB_TTip_NextPage:return "下一页";

 471:                 case PreviewStringId.TB_TTip_PageSetup:return "页面设置";

 472:                 case PreviewStringId.TB_TTip_PreviousPage:return "上一页";

 473:                 case PreviewStringId.TB_TTip_Print:return "打印";

 474:                 case PreviewStringId.TB_TTip_PrintDirect:return "直接打印";

 475:                 case PreviewStringId.TB_TTip_Search:return "搜索";

 476:                 case PreviewStringId.TB_TTip_Send:return "发送E-Mail";

 477:                 case PreviewStringId.TB_TTip_Watermark:return "水印";

 478:                 case PreviewStringId.TB_TTip_Zoom:return "缩放";

 479:                 case PreviewStringId.TB_TTip_ZoomIn:return "放大";

 480:                 case PreviewStringId.TB_TTip_ZoomOut:return "缩小";

 481:                 case PreviewStringId.WMForm_Direction_BackwardDiagonal:return "反向倾斜";

 482:                 case PreviewStringId.WMForm_Direction_ForwardDiagonal:return "正向倾斜";

 483:                 case PreviewStringId.WMForm_Direction_Horizontal:return "横向";

 484:                 case PreviewStringId.WMForm_Direction_Vertical:return "纵向";

 485:                 case PreviewStringId.WMForm_HorzAlign_Center:return "置中";

 486:                 case PreviewStringId.WMForm_HorzAlign_Left:return "靠左";

 487:                 case PreviewStringId.WMForm_HorzAlign_Right:return "靠右";

 488:                 case PreviewStringId.WMForm_ImageClip:return "剪辑";

 489:                 case PreviewStringId.WMForm_ImageStretch:return "伸展";

 490:                 case PreviewStringId.WMForm_ImageZoom:return "缩放";

 491:                 case PreviewStringId.WMForm_PageRangeRgrItem_All:return "全部";

 492:                 case PreviewStringId.WMForm_PageRangeRgrItem_Pages:return "页码";

 493:                 case PreviewStringId.WMForm_PictureDlg_Title:return "选择图片";

 494:                 case PreviewStringId.WMForm_VertAlign_Bottom:return "底端";

 495:                 case PreviewStringId.WMForm_VertAlign_Middle:return "中间";

 496:                 case PreviewStringId.WMForm_VertAlign_Top:return "顶端";

 497:                 case PreviewStringId.WMForm_Watermark_Asap:return "ASAP";

 498:                 case PreviewStringId.WMForm_Watermark_Confidential:return "CONFIDENTIAL";

 499:                 case PreviewStringId.WMForm_Watermark_Copy:return "COPY";

 500:                 case PreviewStringId.WMForm_Watermark_DoNotCopy:return "DO NOT COPY";

 501:                 case PreviewStringId.WMForm_Watermark_Draft:return "DRAFT";

 502:                 case PreviewStringId.WMForm_Watermark_Evaluation:return "EVALUATION";

 503:                 case PreviewStringId.WMForm_Watermark_Original:return "ORIGINAL";

 504:                 case PreviewStringId.WMForm_Watermark_Personal:return "PERSONAL";

 505:                 case PreviewStringId.WMForm_Watermark_Sample:return "SAMPLE";

 506:                 case PreviewStringId.WMForm_Watermark_TopSecret:return "TOP SECRET";

 507:                 case PreviewStringId.WMForm_Watermark_Urgent:return "URGENT";

 508:                 case PreviewStringId.WMForm_ZOrderRgrItem_Behind:return "在后面";

 509:                 case PreviewStringId.WMForm_ZOrderRgrItem_InFront:return "在前面";

 510:             }

 511:             return base.GetLocalizedString(id);

 512:         }

 513:     }

 514:  

 515:  

 516:     public class XtraReports_CN :ReportLocalizer

 517:     {

 518:         public override string Language

 519:         {

 520:             get

 521:             {

 522:                 return "简体中文";

 523:             }

 524:         }

 525:  

 526:         public override string GetLocalizedString(ReportStringId id)

 527:         {

 528:             switch(id)

 529:             {

 530:                 case ReportStringId.BandDsg_QuantityPerPage:return "一个页面集合";

 531:                 case ReportStringId.BandDsg_QuantityPerReport:return "一个报表集合";

 532:                 case ReportStringId.BCForm_Lbl_Binding:return "结合";

 533:                 case ReportStringId.BCForm_Lbl_Property:return "属性";

 534:                 case ReportStringId.CatAppearance:return "版面";

 535:                 case ReportStringId.CatBehavior:return "状态";

 536:                 case ReportStringId.CatData:return "数据";

 537:                 case ReportStringId.CatLayout:return "布局";

 538:                 case ReportStringId.CatNavigation:return "导航";

 539:                 case ReportStringId.CatPageSettings:return "页面设置";

 540:                 case ReportStringId.Cmd_AlignToGrid:return "对齐网格线";

 541:                 case ReportStringId.Cmd_BottomMargin:return "底端边缘";

 542:                 case ReportStringId.Cmd_BringToFront:return "移到最上层";

 543:                 case ReportStringId.Cmd_Copy:return "复制";

 544:                 case ReportStringId.Cmd_Cut:return "剪贴";

 545:                 case ReportStringId.Cmd_Delete:return "删除";

 546:                 case ReportStringId.Cmd_Detail:return "详细";

 547:                 case ReportStringId.Cmd_DetailReport:return "详细报表";

 548:                 case ReportStringId.Cmd_GroupFooter:return "群组尾";

 549:                 case ReportStringId.Cmd_GroupHeader:return "群组首";

 550:                 case ReportStringId.Cmd_InsertBand:return "插入区段";

 551:                 case ReportStringId.Cmd_InsertDetailReport:return "插入详细报表";

 552:                 case ReportStringId.Cmd_InsertUnboundDetailReport:return "非绑定";

 553:                 case ReportStringId.Cmd_PageFooter:return "页尾";

 554:                 case ReportStringId.Cmd_PageHeader:return "页首";

 555:                 case ReportStringId.Cmd_Paste:return "粘贴";

 556:                 case ReportStringId.Cmd_Properties:return "属性";

 557:                 case ReportStringId.Cmd_ReportFooter:return "报表尾";

 558:                 case ReportStringId.Cmd_ReportHeader:return "报表首";

 559:                 case ReportStringId.Cmd_RtfClear:return "清除";

 560:                 case ReportStringId.Cmd_RtfLoad:return "加载文件";

 561:                 case ReportStringId.Cmd_SendToBack:return "移到最下层";

 562:                 case ReportStringId.Cmd_TableDelete:return "删除(&L)";

 563:                 case ReportStringId.Cmd_TableDeleteCell:return "单元格(&L)";

 564:                 case ReportStringId.Cmd_TableDeleteColumn:return "列(&C)";

 565:                 case ReportStringId.Cmd_TableDeleteRow:return "行(&R)";

 566:                 case ReportStringId.Cmd_TableInsert:return "插入(&I)";

 567:                 case ReportStringId.Cmd_TableInsertCell:return "单元格(&C)";

 568:                 case ReportStringId.Cmd_TableInsertColumnToLeft:return "左列(&L)";

 569:                 case ReportStringId.Cmd_TableInsertColumnToRight:return "右列(&R)";

 570:                 case ReportStringId.Cmd_TableInsertRowAbove:return "上行(&A)";

 571:                 case ReportStringId.Cmd_TableInsertRowBelow:return "下行(&B)";

 572:                 case ReportStringId.Cmd_TopMargin:return "顶端边缘";

 573:                 case ReportStringId.Cmd_ViewCode:return "检视代码";

 574:                 case ReportStringId.FindForm_Msg_FinishedSearching:return "搜索文件完成";

 575:                 case ReportStringId.FindForm_Msg_TotalFound:return "合计查找:";

 576:                 case ReportStringId.FSForm_Btn_Delete:return "删除";

 577:                 case ReportStringId.FSForm_GrBox_Sample:return "范例";

 578:                 case ReportStringId.FSForm_Lbl_Category:return "类别";

 579:                 case ReportStringId.FSForm_Lbl_CustomGeneral:return "一般格式不包含特殊数字格式";

 580:                 case ReportStringId.FSForm_Lbl_Prefix:return "上标";

 581:                 case ReportStringId.FSForm_Lbl_Suffix:return "下标";

 582:                 case ReportStringId.FSForm_Msg_BadSymbol:return "损坏的符号";

 583:                 case ReportStringId.FSForm_Tab_Custom:return "自定义";

 584:                 case ReportStringId.FSForm_Tab_StandardTypes:return "标准类型";

 585:                 case ReportStringId.Msg_CantFitBarcodeToControlBounds:return "条形码控件的边界太小";

 586:                 case ReportStringId.Msg_CreateReportInstance:return "您试图打开一个不同类型的报表来编辑。是否确定建立实例?";

 587:                 case ReportStringId.Msg_CreateSomeInstance:return "在窗体中不能建立两个实例类。";

 588:                 case ReportStringId.Msg_CyclicBoormarks:return "报表循环书签";

 589:                 case ReportStringId.Msg_DontSupportMulticolumn:return "详细报表不支持多字段。";

 590:                 case ReportStringId.Msg_FileCorrupted:return "不能加载报表,文件可能被破坏或者报表组件丢失。";

 591:                 case ReportStringId.Msg_FileNotFound:return "文件没有找到";

 592:                 case ReportStringId.Msg_FillDataError:return "数据加载时发生错误。错误为:";

 593:                 case ReportStringId.Msg_IncorrectArgument:return "参数值输入不正确";

 594:                 case ReportStringId.Msg_IncorrectBandType:return "无效的带型";

 595:                 case ReportStringId.Msg_InvalidBarcodeText:return "在文本中有无效的字符";

 596:                 case ReportStringId.Msg_InvalidBarcodeTextFormat:return "无效的文本格式";

 597:                 case ReportStringId.Msg_InvalidMethodCall:return "对象的当前状态下不能调用此方法";

 598:                 case ReportStringId.Msg_InvalidReportSource:return "无法设置原报表";

 599:                 case ReportStringId.Msg_InvPropName:return "无效的属性名";

 600:                 case ReportStringId.Msg_ScriptError:return "在脚本中发现错误: {0}";

 601:                 case ReportStringId.Msg_ScriptExecutionError:return "在脚本执行过程中发现错误 {0}:  {1} 过程 {0} 被运行,将不能再被调用。";

 602:                 case ReportStringId.Msg_WrongReportClassName:return "一个错误发生在并行化期间 - 可能是报表类名错误";

 603:                 case ReportStringId.MultiColumnDesignMsg1:return "重复列之间的空位";

 604:                 case ReportStringId.MultiColumnDesignMsg2:return "控件位置不正确,将会导致打印错误";

 605:                 case ReportStringId.PanelDesignMsg:return "在此可放置不同控件";

 606:                 case ReportStringId.RepTabCtl_Designer:return "设计";

 607:                 case ReportStringId.RepTabCtl_HtmlView:return "HTML视图";

 608:                 case ReportStringId.RepTabCtl_Preview:return "预览";

 609:                 case ReportStringId.SSForm_Btn_Close:return "关闭";

 610:                 case ReportStringId.SSForm_Caption:return "式样单编辑";

 611:                 case ReportStringId.SSForm_Msg_FileFilter:return "Report StyleSheet files (*.repss)|*.repss|All files (*.*)|*.*";

 612:                 case ReportStringId.SSForm_Msg_InvalidFileFormat:return "无效的文件格式";

 613:                 case ReportStringId.SSForm_Msg_MoreThanOneStyle:return "你选择了多过一个以上的式样";

 614:                 case ReportStringId.SSForm_Msg_NoStyleSelected:return "没有式样被选中";

 615:                 case ReportStringId.SSForm_Msg_SelectedStylesText:return "被选中的式样";

 616:                 case ReportStringId.SSForm_Msg_StyleNamePreviewPostfix:return "式样";

 617:                 case ReportStringId.SSForm_Msg_StyleSheetError:return "StyleSheet错误";

 618:                 case ReportStringId.SSForm_TTip_AddStyle:return "添加式样";

 619:                 case ReportStringId.SSForm_TTip_ClearStyles:return "清除式样";

 620:                 case ReportStringId.SSForm_TTip_LoadStyles:return "从文件中读入式样";

 621:                 case ReportStringId.SSForm_TTip_PurgeStyles:return "清除式样";

 622:                 case ReportStringId.SSForm_TTip_RemoveStyle:return "移除式样";

 623:                 case ReportStringId.SSForm_TTip_SaveStyles:return "保存式样到文件";

 624:                 case ReportStringId.UD_FormCaption:return "XtraReport设计";

 625:                 case ReportStringId.UD_Msg_ReportChanged:return "报表内容已被修改,是否须要储存?";

 626:                 case ReportStringId.UD_ReportDesigner:return "XtraReport设计";

 627:                 case ReportStringId.UD_TTip_AlignBottom:return "对齐主控项的下缘";

 628:                 case ReportStringId.UD_TTip_AlignHorizontalCenters:return "对齐主控项的垂直中间";

 629:                 case ReportStringId.UD_TTip_AlignLeft:return "对齐主控项的左缘";

 630:                 case ReportStringId.UD_TTip_AlignRight:return "对齐主控项的右缘";

 631:                 case ReportStringId.UD_TTip_AlignToGrid:return "对齐网格线";

 632:                 case ReportStringId.UD_TTip_AlignTop:return "对齐主控项的上缘";

 633:                 case ReportStringId.UD_TTip_AlignVerticalCenters:return "对齐主控项的水平中央";

 634:                 case ReportStringId.UD_TTip_BringToFront:return "移到最上层";

 635:                 case ReportStringId.UD_TTip_CenterHorizontally:return "水平置中";

 636:                 case ReportStringId.UD_TTip_CenterVertically:return "垂直置中";

 637:                 case ReportStringId.UD_TTip_EditCopy:return "复制";

 638:                 case ReportStringId.UD_TTip_EditCut:return "剪贴";

 639:                 case ReportStringId.UD_TTip_EditPaste:return "粘贴";

 640:                 case ReportStringId.UD_TTip_FileOpen:return "打开文件";

 641:                 case ReportStringId.UD_TTip_FileSave:return "保存文件";

 642:                 case ReportStringId.UD_TTip_FormatAlignLeft:return "左对齐";

 643:                 case ReportStringId.UD_TTip_FormatAlignRight:return "右对齐";

 644:                 case ReportStringId.UD_TTip_FormatBackColor:return "背景颜色";

 645:                 case ReportStringId.UD_TTip_FormatBold:return "粗体";

 646:                 case ReportStringId.UD_TTip_FormatCenter:return "居中";

 647:                 case ReportStringId.UD_TTip_FormatFontName:return "字体";

 648:                 case ReportStringId.UD_TTip_FormatFontSize:return "大小";

 649:                 case ReportStringId.UD_TTip_FormatForeColor:return "前景颜色";

 650:                 case ReportStringId.UD_TTip_FormatItalic:return "斜体";

 651:                 case ReportStringId.UD_TTip_FormatJustify:return "两端对齐";

 652:                 case ReportStringId.UD_TTip_FormatUnderline:return "下划线";            

 653:                 case ReportStringId.UD_TTip_HorizSpaceConcatenate:return "移除水平间距";

 654:                 case ReportStringId.UD_TTip_HorizSpaceDecrease:return "减少水平间距";

 655:                 case ReportStringId.UD_TTip_HorizSpaceIncrease:return "增加水平间距";

 656:                 case ReportStringId.UD_TTip_HorizSpaceMakeEqual:return "将垂直间距设为相等";

 657:                 case ReportStringId.UD_TTip_Redo:return "恢复";

 658:                 case ReportStringId.UD_TTip_SendToBack:return "移到最下层";

 659:                 case ReportStringId.UD_TTip_SizeToControl:return "设置成相同大小";

 660:                 case ReportStringId.UD_TTip_SizeToControlHeight:return "设置成相同高度";

 661:                 case ReportStringId.UD_TTip_SizeToControlWidth:return "设置成相同宽度";

 662:                 case ReportStringId.UD_TTip_SizeToGrid:return "依网格线调整大小";

 663:                 case ReportStringId.UD_TTip_Undo:return "撤消";

 664:                 case ReportStringId.UD_TTip_VertSpaceConcatenate:return "移除垂直间距";

 665:                 case ReportStringId.UD_TTip_VertSpaceDecrease:return "减少垂直间距";

 666:                 case ReportStringId.UD_TTip_VertSpaceIncrease:return "增加垂直间距";

 667:                 case ReportStringId.UD_TTip_VertSpaceMakeEqual:return "将垂直间距设为相等";         

 668:             }

 669:             return base.GetLocalizedString(id);

 670:         }

 671:     }

 672:  

 673:     

 674:     public class XtraTreeList_CN :TreeListLocalizer

 675:     {

 676:         public override string Language

 677:         {

 678:             get

 679:             {

 680:                 return "简体中文";

 681:             }

 682:         }

 683:  

 684:         public override string GetLocalizedString(TreeListStringId id)

 685:         {

 686:             switch(id)

 687:             {

 688:                 case TreeListStringId.ColumnCustomizationText:return "自定显示字段";

 689:                 case TreeListStringId.ColumnNamePrefix:return "列名首标";

 690:                 case TreeListStringId.InvalidNodeExceptionText:return "是否确定要修改?";

 691:                 case TreeListStringId.MenuColumnBestFit:return "最佳匹配";

 692:                 case TreeListStringId.MenuColumnBestFitAllColumns:return "最佳匹配(所有列)";

 693:                 case TreeListStringId.MenuColumnColumnCustomization:return "列选择";

 694:                 case TreeListStringId.MenuColumnSortAscending:return "升序排序";

 695:                 case TreeListStringId.MenuColumnSortDescending:return "降序排序";

 696:                 case TreeListStringId.MenuFooterAllNodes:return "全部节点";

 697:                 case TreeListStringId.MenuFooterAverage:return "平均";

 698:                 case TreeListStringId.MenuFooterAverageFormat:return "平均值={0:#.##}";

 699:                 case TreeListStringId.MenuFooterCount:return "计数";

 700:                 case TreeListStringId.MenuFooterCountFormat:return "{0}";

 701:                 case TreeListStringId.MenuFooterMax:return "最大值";

 702:                 case TreeListStringId.MenuFooterMaxFormat:return "最大值={0}";

 703:                 case TreeListStringId.MenuFooterMin:return "最小值";

 704:                 case TreeListStringId.MenuFooterMinFormat:return "最小值={0}";

 705:                 case TreeListStringId.MenuFooterNone:return "无";

 706:                 case TreeListStringId.MenuFooterSum:return "合计";

 707:                 case TreeListStringId.MenuFooterSumFormat:return "合计={0:#.##}";

 708:                 case TreeListStringId.MultiSelectMethodNotSupported:return "OptionsBehavior.MultiSelect未激活时,指定方法不能工作.";

 709:                 case TreeListStringId.PrintDesignerDescription:return "为当前的树状列表设置不同的打印选项.";

 710:                 case TreeListStringId.PrintDesignerHeader:return "打印设置";

 711:             }

 712:             return base.GetLocalizedString(id);

 713:         }

 714:     }

 715:  

 716:     

 717:     public class XtraVerticalGrid_CN :VGridLocalizer

 718:     {

 719:         public override string Language

 720:         {

 721:             get

 722:             {

 723:                 return "简体中文";

 724:             }

 725:         }

 726:         public override string GetLocalizedString(VGridStringId id)

 727:         {

 728:             switch(id)

 729:             {

 730:                 case VGridStringId.InvalidRecordExceptionText:return "是否确定修改?";

 731:                 case VGridStringId.RowCustomizationDeleteCategoryText:return "删除";

 732:                 case VGridStringId.RowCustomizationNewCategoryFormLabelText:return "标题";

 733:                 case VGridStringId.RowCustomizationNewCategoryFormText:return "新增类别";

 734:                 case VGridStringId.RowCustomizationNewCategoryText:return "新增";

 735:                 case VGridStringId.RowCustomizationTabPageCategoriesText:return "类别";

 736:                 case VGridStringId.RowCustomizationTabPageRowsText:return "行";

 737:                 case VGridStringId.RowCustomizationText:return "自定义";

 738:                 case VGridStringId.StyleCreatorName:return "自定义式样";

 739:             }

 740:             return base.GetLocalizedString(id);

 741:         }

 742:     }

 743:  

 744: }

>>下载

2)报表特殊元素的处理

RDLC报表,也有一些如打印时间,分页数据等,是需要特殊的处理了,打印时间是使用报表数据里面的【内置字段】项目,如下所示。

图片 9 

对于记录总数和统计值,我们可以通过自定义的格式内容进行处理,如下所示。

图片 10

统计总数的操作设计如下,调用SUM函数即可,如果忘记是那个,可以在下面类别里面进行查询,里面有很多运算符、常见函数等内容可以使用。

图片 11

另外,对于一些特殊的显示格式,我们需要正确设置,如下是日期的格式设置。

图片 12

 

DevExpress.Data.v10.1

DevExpress.XtraVerticalGrid

Spreadsheet Document Server

Workbook类的以下事件被删除:

  • ActiveSheetChanging;
  • ActiveSheetChanged;
  • ColumnsRemoved;
  • ColumnsInserted.
  • SelectionChanged;
  • SheetRenaming;
  • SheetRenamed;
  • SheetInserted;
  • SheetRemoved;
  • RowsRemoved;
  • RowsInserted;

另外,提醒大家注意一下DevExpress发现的一个问题。这个bug将会在下一个版本中修复:

  • 如果CopyLocal属性被禁用,XtraReports LightSwitch
    demo无法在VS2013下运行

DXperience Universal Suite
13.1.7更多详细更新请移步>>

1)RDLC的设计效果

图片 13

由于RDLC它是一个独立的XML文件,它的描述全部在一个XML里面,因此我们设计的时候,只是对XML文件进行处理,VS给我们提供了一个设计器及进行设计而已。

在RDLC的设计视图里面,我们可以看到报表数据里面,包括一些预定义的数据,以及我们添加进去的数据源。

图片 14

当然报表设计少不了相关的控件,因此在工具栏里面,可以看到可以用的报表控件元素,如下所示。

图片 15

 1 using DevExpress.XtraReports.UI;
 2 
 3 private static bool PrintRepx()
 4         {
 5             try
 6             {
 7                 XtraReport printTemplate = new XtraReport();
 8 
 9                 string fileName = "D:\模板.repx";
10                 DataTable dtRpt = new DataTable();
11                 dtRpt.Columns.Add("二维码", typeof(int));
12                 dtRpt.Rows.Add(1233);
13 
14                 printTemplate.LoadLayout(fileName);
15                 printTemplate.DataSource = dtRpt.DefaultView;
16                 printTemplate.CreateDocument();
17 
18                 ReportPrintTool printTool = new ReportPrintTool(printTemplate);
19                 printTool.Print();
20                 return true;
21             }
22             catch (Exception ex)
23             {
24                 return false;
25             }
26         }

3)设计报表控件和数据源管理

在VS左边的工具箱里面有响应的XtraReport控件,拖动到报表界面里面就可以进行绘制设计了。

图片 16

为了实现表格统计和展示,我们需要拖动两个表格到报表界面里面去,一个是报表头字段,一个用来显示报表明细的列表内容,两个单元格的宽度设置一致,并且上下空间要挨着,否则显示出来就有空间,不好看。

表格拖动过去后,可以使用右键添加相应的单元格,然后统一设置他们的背景颜色,高度宽度,边框等属性即可。

表格头我们可以填写相关的文字替代,但是报表的明细信息,我们需要绑定相应的字段内容,因此需要增加一个数据源用来绑定到报表上去。

在报表属性里面,找到DataSource进行配置,如下所示。

图片 17

拖动相关的表格,然后设计其界面,并绑定明细单元格的内容为[ABC]这样的格式,就标识绑定了一个ABC的字段属性了。如下所示是绑定了一个HandNo的字段显示。

图片 18

 最终设计的报表界面如下所示。

图片 19

首先需要添加Dll引用

2、RDLC报表的使用

在我《会员管理系统的设计和开发(2)–
RDLC报表的设计及动态加载》里面,有对RDLC报表设计做了一些介绍,RDLC是微软的报表格式,它是一个相对比较独立的文件,是一个基于XML描述性的文件,除了可以用在Winform上外,也可以用在Web上,通用性也非常不错。

基于对比的考虑,我也为同样的模块设计了一个一样的报表,RDLC报表最终展示界面如下所示。

图片 20

 和前面XtraReport的报表界面做一个对比。

图片 8

两者的展现效果都差不多,只是界面效果有一些差异而已。

使用的模板也是存放在服务器上的。

3、XtraReport报表和RDLC报的差异

这两者的报表都能实现相似的效果,不过XtraReport是把它集成到DLL里面,类似编译的窗体文件一样了;而RDLC报表本身是一个独立的文件,我们发布的时候,要把它带上,但是又有较好的通用性。

对于XtraReport的字段内容展示,默认就是调用了ToString()的函数处理,因此类似日期、枚举类型,都不需要怎么样设置,就可以正常显示,但是RDLC报表设计里面,我们需要为每种字段设置好对应的格式,枚举类型好像解析还是会转换为整形,因此需要在数据源级别进行转换,否则显示不出来。

对于自定义函数方面,XtraReport提供了较好的设计界面,能够很大程度减少出错的机会;RDLC则提供了弹性化的操作,提供了很多函数进行参考,需要自己添加表达式,不过在编译的时候,能够检查出现的错误。

如果需要动态配置、加载或者开发一些新的报表展示,可能相对来说,RDLC更方便,可以增量发布一些报表,然后在后台配置即可展示,不需要改动源码编译。

 

DevExpress.XtraReports.v10.1

 3)报表的调用处理

由于报表的展现模块,我已经放到了一个独立的通用模块里面,因此对于报表的加载,只需要简单的设置属性,然后调用即可,如下所示。

        private void PrintRDLCReport()
        {
            string where = GetConditionSql();
            List<CarApplyInfo> list = BLLFactory<CarApply>.Instance.Find(where);
            foreach (CarApplyInfo info in list)
            {
                info.Data1 = info.Status.ToString();//转换枚举类型描述
            }

            ReportViewerDialog dlg = new ReportViewerDialog();
            dlg.Text = "历史记录报表";
            dlg.DataSourceDict.Add("CarApplyInfo", list);
            dlg.ReportName = "WHC.CarDispatch.HistoryReport";
            dlg.IsPrintLayout = true;

            dlg.ShowDialog();
        }

上面主要也是构建数据源,指定报表路径和布局,然后绑定报表展示模块窗口即可。 

下面附上几个系统功能截图,供参考学习。

1)主界面列表,基于GridControl的展示,并增加统计栏目。

图片 22

2)历史记录报表展示(XtraReport报表)

图片 23

3)两种不同格式的派车单报表展示(RDLC报表)。

图片 24

图片 25

 

本文使用的DEV版本为10.1版本 

1、XtraReport报表的使用