DevExpress控件使用交流,DevExpress中国社区Dev联系电话 联系电话:023-68661681

DevExpress WPF 常用代码集锦

来源:   发布时间:2017-10-27   浏览:3991次

1. 在创建的组中实现只能选中一个项目

<Window
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:dxb="http://schemas.devexpress.com/winfx/2008/xaml/bars" 
        xmlns:dxe="http://schemas.devexpress.com/winfx/2008/xaml/editors"
        xmlns:dx="http://schemas.devexpress.com/winfx/2008/xaml/core" x:Class="WpfApplication302.MainWindow"
        Title="MainWindow" Height="350" Width="525">
    <Grid>
        <DockPanel>
            <dxb:ToolBarControl Caption="Edit" DockPanel.Dock="Top">
                <dxb:BarItemSelector>
                    <dxb:BarCheckItem Glyph="{dx:DXImage Image=3DColumn_16x16.png}"/>
                    <dxb:BarCheckItem Glyph="{dx:DXImage Image=3DFullStackedArea_32x32.png}"/>
                    <dxb:BarCheckItem Glyph="{dx:DXImage 

2. 报表打印

using System;
using System.Windows.Forms;
using DevExpress.XtraReports.UI;

namespace PrintReport {
    public partial class Form1 : Form {
        public Form1() {
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e) {
            // Create a report instance, assigned to a Print Tool.
            ReportPrintTool pt = new ReportPrintTool(new XtraReport1());

3. 手动添加DXSplashScreen控件

// Developer Express Code Central Example:
// How to manually invoke and close DXSplashScreen
// 
// This example shows how to manually invoke and close DXSplashScreen. By default,
// DXSplashScreen contains a progress bar, indicating the progress of the
// application load. This example also shows how you can manually change the
// progress in code.
// 
// You can find sample updates and versions for different programming languages here:
// http://www.devexpress.com/example=E3243

 

素材来源:DevExpress控件中文网 [https://www.devexpresscn.com/]

本站文章除注明转载外,均为本站原创或翻译
欢迎任何形式的转载,但请务必注明出处,尊重他人劳动成果
转载请注明:文章转载自:DevExpress控件中文网 [https://www.devexpresscn.com/]
本文地址:https://www.devexpresscn.com/post/939.html

相关产品: DevExpress Universal Subscription,

在线
客服
微信
QQ 电话
023-68661681
返回
顶部