#region
|
|
using System;
|
using System.Data;
|
using CSFrameworkV5.Common;
|
using DevExpress.XtraBars;
|
|
#endregion
|
|
namespace CSFrameworkV5.Library
|
{
|
public partial class frmBasePrint : frmBase
|
{
|
public frmBasePrint()
|
{
|
InitializeComponent();
|
}
|
|
protected void AssertNull(object o, string throwMsg)
|
{
|
if (o == null) throw new Exception(throwMsg);
|
}
|
|
protected void AssertNullDataSet(DataSet ds, string throwMsg)
|
{
|
if (ds == null || ds.Tables.Count == 0 ||
|
ds.Tables[0].Rows.Count == 0) throw new Exception(throwMsg);
|
}
|
|
private void btnClose_ItemClick(object sender, ItemClickEventArgs e)
|
{
|
DoClose();
|
}
|
|
private void btnDesign_ItemClick(object sender, ItemClickEventArgs e)
|
{
|
DoDesignReport();
|
}
|
|
private void btnHelp_ItemClick(object sender, ItemClickEventArgs e)
|
{
|
DoHelp();
|
}
|
|
private void btnPreview_ItemClick(object sender, ItemClickEventArgs e)
|
{
|
DoPreview();
|
}
|
|
private void btnPrint_ItemClick(object sender, ItemClickEventArgs e)
|
{
|
DoPrint();
|
}
|
|
protected virtual void DoClose()
|
{
|
Close();
|
}
|
|
protected virtual void DoDesignReport()
|
{
|
//
|
}
|
|
protected virtual void DoHelp()
|
{
|
//
|
}
|
|
protected virtual void DoPreview()
|
{
|
//
|
}
|
|
protected virtual void DoPrint()
|
{
|
//
|
}
|
|
private void frmPrintBase_Load(object sender, EventArgs e)
|
{
|
btnClose.Glyph = Globals.LoadImage("24_Exit.ico");
|
btnPrint.Glyph = Globals.LoadImage("24_Print.ico");
|
btnPreview.Glyph = Globals.LoadImage("24_PrintPreview.ico");
|
btnHelp.Glyph = Globals.LoadImage("24_Help.ico");
|
btnDesign.Glyph = Globals.LoadImage("24_DesignReport.ico");
|
}
|
}
|
}
|