StartForm.vb
上传用户:wj57717022
上传日期:2014-12-16
资源大小:4093k
文件大小:68k
源码类别:

医药行业

开发平台:

Visual Basic

  1. Imports DataDynamics.ActiveReports.Design
  2. Imports System.ComponentModel
  3. Imports System.Collections
  4. Imports System
  5. Imports System.Drawing
  6. Imports System.Windows.Forms.ToolBarButtonClickEventArgs
  7. 'Demonstrates a custom end-user report designer that can be integrated in your applications 
  8. ' to allow users to modify report layouts.
  9. Public Class StartForm
  10.     Inherits System.Windows.Forms.Form
  11. #Region " Windows Form Designer generated code "
  12.     Public Sub New()
  13.         MyBase.New()
  14.         'This call is required by the Windows Form Designer.
  15.         InitializeComponent()
  16.         'Add any initialization after the InitializeComponent() call
  17.     End Sub
  18.     'Form overrides dispose to clean up the component list.
  19.     Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
  20.         If disposing Then
  21.             If Not (components Is Nothing) Then
  22.                 components.Dispose()
  23.             End If
  24.         End If
  25.         MyBase.Dispose(disposing)
  26.     End Sub
  27.     'Required by the Windows Form Designer
  28.     Private components As System.ComponentModel.IContainer
  29.     'NOTE: The following procedure is required by the Windows Form Designer
  30.     'It can be modified using the Windows Form Designer.  
  31.     'Do not modify it using the code editor.
  32.     Friend WithEvents Panel1 As System.Windows.Forms.Panel
  33.     Friend WithEvents Panel2 As System.Windows.Forms.Panel
  34.     Friend WithEvents Splitter1 As System.Windows.Forms.Splitter
  35.     Friend WithEvents Designer1 As DataDynamics.ActiveReports.Design.Designer
  36.     Friend WithEvents Panel3 As System.Windows.Forms.Panel
  37.     Friend WithEvents Panel4 As System.Windows.Forms.Panel
  38.     Friend WithEvents Splitter2 As System.Windows.Forms.Splitter
  39.     Friend WithEvents Panel5 As System.Windows.Forms.Panel
  40.     Friend WithEvents ReportExplorer1 As DataDynamics.ActiveReports.Design.ReportExplorer
  41.     Friend WithEvents PropertyGrid1 As System.Windows.Forms.PropertyGrid
  42.     Friend WithEvents Label1 As System.Windows.Forms.Label
  43.     Friend WithEvents Imgtoolbox As System.Windows.Forms.ImageList
  44.     Friend WithEvents ImgLayout As System.Windows.Forms.ImageList
  45.     Friend WithEvents ImgReport As System.Windows.Forms.ImageList
  46.     Friend WithEvents MainMenu1 As System.Windows.Forms.MainMenu
  47.     Friend WithEvents MenuItem4 As System.Windows.Forms.MenuItem
  48.     Friend WithEvents MenuItem7 As System.Windows.Forms.MenuItem
  49.     Friend WithEvents MenuItem10 As System.Windows.Forms.MenuItem
  50.     Friend WithEvents mnuFile As System.Windows.Forms.MenuItem
  51.     Friend WithEvents mnuPrintPreview As System.Windows.Forms.MenuItem
  52.     Friend WithEvents mnuLoadLayout As System.Windows.Forms.MenuItem
  53.     Friend WithEvents mnuSaveLayout As System.Windows.Forms.MenuItem
  54.     Friend WithEvents mnuPageSetup As System.Windows.Forms.MenuItem
  55.     Friend WithEvents mnuExit As System.Windows.Forms.MenuItem
  56.     Friend WithEvents cmbFontSize As System.Windows.Forms.ComboBox
  57.     Friend WithEvents cmbFonts As System.Windows.Forms.ComboBox
  58.     Friend WithEvents cmbClassName As System.Windows.Forms.ComboBox
  59.     Friend WithEvents tlbLayout As System.Windows.Forms.ToolBar
  60.     Friend WithEvents tlbReport As System.Windows.Forms.ToolBar
  61.     Friend WithEvents tbbAligntoGrid As System.Windows.Forms.ToolBarButton
  62.     Private WithEvents tbbLine1 As System.Windows.Forms.ToolBarButton
  63.     Friend WithEvents tbbAlignLefts As System.Windows.Forms.ToolBarButton
  64.     Friend WithEvents tbbAlignCenters As System.Windows.Forms.ToolBarButton
  65.     Friend WithEvents tbbAlignRights As System.Windows.Forms.ToolBarButton
  66.     Private WithEvents tbbLine2 As System.Windows.Forms.ToolBarButton
  67.     Friend WithEvents tbbAlignTops As System.Windows.Forms.ToolBarButton
  68.     Friend WithEvents tbbAlignMiddles As System.Windows.Forms.ToolBarButton
  69.     Friend WithEvents tbbAlignBottoms As System.Windows.Forms.ToolBarButton
  70.     Private WithEvents tbbLine3 As System.Windows.Forms.ToolBarButton
  71.     Friend WithEvents tbbMakeSameWidth As System.Windows.Forms.ToolBarButton
  72.     Friend WithEvents tbbSizeToGrid As System.Windows.Forms.ToolBarButton
  73.     Friend WithEvents tbbMakeSameHeight As System.Windows.Forms.ToolBarButton
  74.     Friend WithEvents tbbMakeSameSize As System.Windows.Forms.ToolBarButton
  75.     Private WithEvents tbbLine4 As System.Windows.Forms.ToolBarButton
  76.     Private WithEvents tbbLine5 As System.Windows.Forms.ToolBarButton
  77.     Private WithEvents tbbLine6 As System.Windows.Forms.ToolBarButton
  78.     Private WithEvents tbbLine7 As System.Windows.Forms.ToolBarButton
  79.     Friend WithEvents tbbBringToFront As System.Windows.Forms.ToolBarButton
  80.     Friend WithEvents tbbSendToBack As System.Windows.Forms.ToolBarButton
  81.     Friend WithEvents tbbMakeHorizSpaceEqual As System.Windows.Forms.ToolBarButton
  82.     Friend WithEvents tbbIncreaseHorizSpace As System.Windows.Forms.ToolBarButton
  83.     Friend WithEvents tbbDecreaseHorizSpace As System.Windows.Forms.ToolBarButton
  84.     Friend WithEvents tbbRemoveHorizSpace As System.Windows.Forms.ToolBarButton
  85.     Friend WithEvents tbbMakeVertSpaceEqual As System.Windows.Forms.ToolBarButton
  86.     Friend WithEvents tbbIncreaseVertSpace As System.Windows.Forms.ToolBarButton
  87.     Friend WithEvents tbbDecreaseVertSpace As System.Windows.Forms.ToolBarButton
  88.     Friend WithEvents tbbRemoveVertSpace As System.Windows.Forms.ToolBarButton
  89.     Friend WithEvents tbbCenterHoriz As System.Windows.Forms.ToolBarButton
  90.     Friend WithEvents tbbCenterVert As System.Windows.Forms.ToolBarButton
  91.     Friend WithEvents tlbARToolbox As System.Windows.Forms.ToolBar
  92.     Private WithEvents tbbLine8 As System.Windows.Forms.ToolBarButton
  93.     Friend WithEvents tbbViewGrid As System.Windows.Forms.ToolBarButton
  94.     Friend WithEvents tbbReorderGroups As System.Windows.Forms.ToolBarButton
  95.     Friend WithEvents tbbEditScript As System.Windows.Forms.ToolBarButton
  96.     Private WithEvents tbbLine9 As System.Windows.Forms.ToolBarButton
  97.     Friend WithEvents tbbBold As System.Windows.Forms.ToolBarButton
  98.     Friend WithEvents tbbItalic As System.Windows.Forms.ToolBarButton
  99.     Friend WithEvents tbbUnderline As System.Windows.Forms.ToolBarButton
  100.     Private WithEvents tbbLine10 As System.Windows.Forms.ToolBarButton
  101.     Friend WithEvents tbbAlignLeft As System.Windows.Forms.ToolBarButton
  102.     Friend WithEvents tbbCenter As System.Windows.Forms.ToolBarButton
  103.     Friend WithEvents tbbAlignRight As System.Windows.Forms.ToolBarButton
  104.     Friend WithEvents tbbJustify As System.Windows.Forms.ToolBarButton
  105.     Private WithEvents tbbLine11 As System.Windows.Forms.ToolBarButton
  106.     Friend WithEvents tbbBullets As System.Windows.Forms.ToolBarButton
  107.     Friend WithEvents tbbDecreaseIndent As System.Windows.Forms.ToolBarButton
  108.     Friend WithEvents tbbIncreaseIndent As System.Windows.Forms.ToolBarButton
  109.     Friend WithEvents tbbPointer As System.Windows.Forms.ToolBarButton
  110.     Friend WithEvents tbbLabel As System.Windows.Forms.ToolBarButton
  111.     Friend WithEvents tbbTextBox As System.Windows.Forms.ToolBarButton
  112.     Friend WithEvents tbbCheckBox As System.Windows.Forms.ToolBarButton
  113.     Friend WithEvents tbbPicture As System.Windows.Forms.ToolBarButton
  114.     Friend WithEvents tbbShape As System.Windows.Forms.ToolBarButton
  115.     Friend WithEvents tbbLine As System.Windows.Forms.ToolBarButton
  116.     Friend WithEvents tbbSubreport As System.Windows.Forms.ToolBarButton
  117.     Friend WithEvents tbbPageBreak As System.Windows.Forms.ToolBarButton
  118.     Friend WithEvents tbbBarcode As System.Windows.Forms.ToolBarButton
  119.     Friend WithEvents tbbRichTextBox As System.Windows.Forms.ToolBarButton
  120.     Friend WithEvents btnLoad As System.Windows.Forms.ToolBarButton
  121.     Friend WithEvents btnSave As System.Windows.Forms.ToolBarButton
  122.     Friend WithEvents btnPrintview As System.Windows.Forms.ToolBarButton
  123.     Friend WithEvents btnPrintSetup As System.Windows.Forms.ToolBarButton
  124.     Friend WithEvents btnExit As System.Windows.Forms.ToolBarButton
  125.     <System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent()
  126.         Me.components = New System.ComponentModel.Container
  127.         Dim resources As System.Resources.ResourceManager = New System.Resources.ResourceManager(GetType(StartForm))
  128.         Me.tlbLayout = New System.Windows.Forms.ToolBar
  129.         Me.tbbAligntoGrid = New System.Windows.Forms.ToolBarButton
  130.         Me.tbbLine1 = New System.Windows.Forms.ToolBarButton
  131.         Me.tbbAlignLefts = New System.Windows.Forms.ToolBarButton
  132.         Me.tbbAlignCenters = New System.Windows.Forms.ToolBarButton
  133.         Me.tbbAlignRights = New System.Windows.Forms.ToolBarButton
  134.         Me.tbbLine2 = New System.Windows.Forms.ToolBarButton
  135.         Me.tbbAlignTops = New System.Windows.Forms.ToolBarButton
  136.         Me.tbbAlignMiddles = New System.Windows.Forms.ToolBarButton
  137.         Me.tbbAlignBottoms = New System.Windows.Forms.ToolBarButton
  138.         Me.tbbLine3 = New System.Windows.Forms.ToolBarButton
  139.         Me.tbbMakeSameWidth = New System.Windows.Forms.ToolBarButton
  140.         Me.tbbSizeToGrid = New System.Windows.Forms.ToolBarButton
  141.         Me.tbbMakeSameHeight = New System.Windows.Forms.ToolBarButton
  142.         Me.tbbMakeSameSize = New System.Windows.Forms.ToolBarButton
  143.         Me.tbbLine4 = New System.Windows.Forms.ToolBarButton
  144.         Me.tbbMakeHorizSpaceEqual = New System.Windows.Forms.ToolBarButton
  145.         Me.tbbIncreaseHorizSpace = New System.Windows.Forms.ToolBarButton
  146.         Me.tbbDecreaseHorizSpace = New System.Windows.Forms.ToolBarButton
  147.         Me.tbbRemoveHorizSpace = New System.Windows.Forms.ToolBarButton
  148.         Me.tbbLine5 = New System.Windows.Forms.ToolBarButton
  149.         Me.tbbMakeVertSpaceEqual = New System.Windows.Forms.ToolBarButton
  150.         Me.tbbIncreaseVertSpace = New System.Windows.Forms.ToolBarButton
  151.         Me.tbbDecreaseVertSpace = New System.Windows.Forms.ToolBarButton
  152.         Me.tbbRemoveVertSpace = New System.Windows.Forms.ToolBarButton
  153.         Me.tbbLine6 = New System.Windows.Forms.ToolBarButton
  154.         Me.tbbCenterHoriz = New System.Windows.Forms.ToolBarButton
  155.         Me.tbbCenterVert = New System.Windows.Forms.ToolBarButton
  156.         Me.tbbLine7 = New System.Windows.Forms.ToolBarButton
  157.         Me.tbbBringToFront = New System.Windows.Forms.ToolBarButton
  158.         Me.tbbSendToBack = New System.Windows.Forms.ToolBarButton
  159.         Me.btnLoad = New System.Windows.Forms.ToolBarButton
  160.         Me.btnSave = New System.Windows.Forms.ToolBarButton
  161.         Me.btnPrintview = New System.Windows.Forms.ToolBarButton
  162.         Me.btnPrintSetup = New System.Windows.Forms.ToolBarButton
  163.         Me.btnExit = New System.Windows.Forms.ToolBarButton
  164.         Me.ImgLayout = New System.Windows.Forms.ImageList(Me.components)
  165.         Me.Panel1 = New System.Windows.Forms.Panel
  166.         Me.tlbARToolbox = New System.Windows.Forms.ToolBar
  167.         Me.tbbPointer = New System.Windows.Forms.ToolBarButton
  168.         Me.tbbLabel = New System.Windows.Forms.ToolBarButton
  169.         Me.tbbTextBox = New System.Windows.Forms.ToolBarButton
  170.         Me.tbbCheckBox = New System.Windows.Forms.ToolBarButton
  171.         Me.tbbPicture = New System.Windows.Forms.ToolBarButton
  172.         Me.tbbShape = New System.Windows.Forms.ToolBarButton
  173.         Me.tbbLine = New System.Windows.Forms.ToolBarButton
  174.         Me.tbbRichTextBox = New System.Windows.Forms.ToolBarButton
  175.         Me.tbbSubreport = New System.Windows.Forms.ToolBarButton
  176.         Me.tbbPageBreak = New System.Windows.Forms.ToolBarButton
  177.         Me.tbbBarcode = New System.Windows.Forms.ToolBarButton
  178.         Me.Imgtoolbox = New System.Windows.Forms.ImageList(Me.components)
  179.         Me.Label1 = New System.Windows.Forms.Label
  180.         Me.Panel2 = New System.Windows.Forms.Panel
  181.         Me.Panel5 = New System.Windows.Forms.Panel
  182.         Me.ReportExplorer1 = New DataDynamics.ActiveReports.Design.ReportExplorer
  183.         Me.Designer1 = New DataDynamics.ActiveReports.Design.Designer
  184.         Me.Splitter2 = New System.Windows.Forms.Splitter
  185.         Me.Panel4 = New System.Windows.Forms.Panel
  186.         Me.PropertyGrid1 = New System.Windows.Forms.PropertyGrid
  187.         Me.Splitter1 = New System.Windows.Forms.Splitter
  188.         Me.Panel3 = New System.Windows.Forms.Panel
  189.         Me.tlbReport = New System.Windows.Forms.ToolBar
  190.         Me.tbbViewGrid = New System.Windows.Forms.ToolBarButton
  191.         Me.tbbReorderGroups = New System.Windows.Forms.ToolBarButton
  192.         Me.tbbLine8 = New System.Windows.Forms.ToolBarButton
  193.         Me.tbbEditScript = New System.Windows.Forms.ToolBarButton
  194.         Me.tbbLine9 = New System.Windows.Forms.ToolBarButton
  195.         Me.tbbBold = New System.Windows.Forms.ToolBarButton
  196.         Me.tbbItalic = New System.Windows.Forms.ToolBarButton
  197.         Me.tbbUnderline = New System.Windows.Forms.ToolBarButton
  198.         Me.tbbLine10 = New System.Windows.Forms.ToolBarButton
  199.         Me.tbbAlignLeft = New System.Windows.Forms.ToolBarButton
  200.         Me.tbbCenter = New System.Windows.Forms.ToolBarButton
  201.         Me.tbbAlignRight = New System.Windows.Forms.ToolBarButton
  202.         Me.tbbJustify = New System.Windows.Forms.ToolBarButton
  203.         Me.tbbLine11 = New System.Windows.Forms.ToolBarButton
  204.         Me.tbbBullets = New System.Windows.Forms.ToolBarButton
  205.         Me.tbbDecreaseIndent = New System.Windows.Forms.ToolBarButton
  206.         Me.tbbIncreaseIndent = New System.Windows.Forms.ToolBarButton
  207.         Me.ImgReport = New System.Windows.Forms.ImageList(Me.components)
  208.         Me.cmbFontSize = New System.Windows.Forms.ComboBox
  209.         Me.cmbFonts = New System.Windows.Forms.ComboBox
  210.         Me.cmbClassName = New System.Windows.Forms.ComboBox
  211.         Me.MainMenu1 = New System.Windows.Forms.MainMenu
  212.         Me.mnuFile = New System.Windows.Forms.MenuItem
  213.         Me.mnuPrintPreview = New System.Windows.Forms.MenuItem
  214.         Me.MenuItem4 = New System.Windows.Forms.MenuItem
  215.         Me.mnuLoadLayout = New System.Windows.Forms.MenuItem
  216.         Me.mnuSaveLayout = New System.Windows.Forms.MenuItem
  217.         Me.MenuItem7 = New System.Windows.Forms.MenuItem
  218.         Me.mnuPageSetup = New System.Windows.Forms.MenuItem
  219.         Me.MenuItem10 = New System.Windows.Forms.MenuItem
  220.         Me.mnuExit = New System.Windows.Forms.MenuItem
  221.         Me.Panel1.SuspendLayout()
  222.         Me.Panel2.SuspendLayout()
  223.         Me.Panel5.SuspendLayout()
  224.         Me.Panel4.SuspendLayout()
  225.         Me.Panel3.SuspendLayout()
  226.         Me.SuspendLayout()
  227.         '
  228.         'tlbLayout
  229.         '
  230.         Me.tlbLayout.Appearance = System.Windows.Forms.ToolBarAppearance.Flat
  231.         Me.tlbLayout.Buttons.AddRange(New System.Windows.Forms.ToolBarButton() {Me.tbbAligntoGrid, Me.tbbLine1, Me.tbbAlignLefts, Me.tbbAlignCenters, Me.tbbAlignRights, Me.tbbLine2, Me.tbbAlignTops, Me.tbbAlignMiddles, Me.tbbAlignBottoms, Me.tbbLine3, Me.tbbMakeSameWidth, Me.tbbSizeToGrid, Me.tbbMakeSameHeight, Me.tbbMakeSameSize, Me.tbbLine4, Me.tbbMakeHorizSpaceEqual, Me.tbbIncreaseHorizSpace, Me.tbbDecreaseHorizSpace, Me.tbbRemoveHorizSpace, Me.tbbLine5, Me.tbbMakeVertSpaceEqual, Me.tbbIncreaseVertSpace, Me.tbbDecreaseVertSpace, Me.tbbRemoveVertSpace, Me.tbbLine6, Me.tbbCenterHoriz, Me.tbbCenterVert, Me.tbbLine7, Me.tbbBringToFront, Me.tbbSendToBack, Me.btnLoad, Me.btnSave, Me.btnPrintview, Me.btnPrintSetup, Me.btnExit})
  232.         Me.tlbLayout.DropDownArrows = True
  233.         Me.tlbLayout.ImageList = Me.ImgLayout
  234.         Me.tlbLayout.Location = New System.Drawing.Point(0, 0)
  235.         Me.tlbLayout.Name = "tlbLayout"
  236.         Me.tlbLayout.ShowToolTips = True
  237.         Me.tlbLayout.Size = New System.Drawing.Size(1028, 41)
  238.         Me.tlbLayout.TabIndex = 0
  239.         '
  240.         'tbbAligntoGrid
  241.         '
  242.         Me.tbbAligntoGrid.ImageIndex = 0
  243.         Me.tbbAligntoGrid.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  244.         Me.tbbAligntoGrid.Tag = "AligntoGrid"
  245.         Me.tbbAligntoGrid.ToolTipText = "AligntoGrid"
  246.         '
  247.         'tbbLine1
  248.         '
  249.         Me.tbbLine1.Style = System.Windows.Forms.ToolBarButtonStyle.Separator
  250.         '
  251.         'tbbAlignLefts
  252.         '
  253.         Me.tbbAlignLefts.ImageIndex = 1
  254.         Me.tbbAlignLefts.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  255.         Me.tbbAlignLefts.Tag = "AlignLefts"
  256.         Me.tbbAlignLefts.ToolTipText = "AlignLefts"
  257.         '
  258.         'tbbAlignCenters
  259.         '
  260.         Me.tbbAlignCenters.ImageIndex = 2
  261.         Me.tbbAlignCenters.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  262.         Me.tbbAlignCenters.Tag = "AlignCenters"
  263.         Me.tbbAlignCenters.ToolTipText = "AlignCenters"
  264.         '
  265.         'tbbAlignRights
  266.         '
  267.         Me.tbbAlignRights.ImageIndex = 3
  268.         Me.tbbAlignRights.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  269.         Me.tbbAlignRights.Tag = "AlignRights"
  270.         Me.tbbAlignRights.ToolTipText = "AlignRights"
  271.         '
  272.         'tbbLine2
  273.         '
  274.         Me.tbbLine2.Style = System.Windows.Forms.ToolBarButtonStyle.Separator
  275.         '
  276.         'tbbAlignTops
  277.         '
  278.         Me.tbbAlignTops.ImageIndex = 4
  279.         Me.tbbAlignTops.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  280.         Me.tbbAlignTops.Tag = "AlignTops"
  281.         Me.tbbAlignTops.ToolTipText = "AlignTops"
  282.         '
  283.         'tbbAlignMiddles
  284.         '
  285.         Me.tbbAlignMiddles.ImageIndex = 5
  286.         Me.tbbAlignMiddles.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  287.         Me.tbbAlignMiddles.Tag = "AlignMiddles"
  288.         Me.tbbAlignMiddles.ToolTipText = "AlignMiddles"
  289.         '
  290.         'tbbAlignBottoms
  291.         '
  292.         Me.tbbAlignBottoms.ImageIndex = 6
  293.         Me.tbbAlignBottoms.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  294.         Me.tbbAlignBottoms.Tag = "AlignBottoms"
  295.         Me.tbbAlignBottoms.ToolTipText = "AlignBottoms"
  296.         '
  297.         'tbbLine3
  298.         '
  299.         Me.tbbLine3.Style = System.Windows.Forms.ToolBarButtonStyle.Separator
  300.         '
  301.         'tbbMakeSameWidth
  302.         '
  303.         Me.tbbMakeSameWidth.ImageIndex = 7
  304.         Me.tbbMakeSameWidth.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  305.         Me.tbbMakeSameWidth.Tag = "MakeSameWidth"
  306.         Me.tbbMakeSameWidth.ToolTipText = "MakeSameWidth"
  307.         '
  308.         'tbbSizeToGrid
  309.         '
  310.         Me.tbbSizeToGrid.ImageIndex = 8
  311.         Me.tbbSizeToGrid.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  312.         Me.tbbSizeToGrid.Tag = "SizeToGrid"
  313.         Me.tbbSizeToGrid.ToolTipText = "SizeToGrid"
  314.         '
  315.         'tbbMakeSameHeight
  316.         '
  317.         Me.tbbMakeSameHeight.ImageIndex = 9
  318.         Me.tbbMakeSameHeight.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  319.         Me.tbbMakeSameHeight.Tag = "MakeSameHeight"
  320.         Me.tbbMakeSameHeight.ToolTipText = "MakeSameHeight"
  321.         '
  322.         'tbbMakeSameSize
  323.         '
  324.         Me.tbbMakeSameSize.ImageIndex = 10
  325.         Me.tbbMakeSameSize.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  326.         Me.tbbMakeSameSize.Tag = "MakeSameSize"
  327.         Me.tbbMakeSameSize.ToolTipText = "MakeSameSize"
  328.         '
  329.         'tbbLine4
  330.         '
  331.         Me.tbbLine4.Style = System.Windows.Forms.ToolBarButtonStyle.Separator
  332.         '
  333.         'tbbMakeHorizSpaceEqual
  334.         '
  335.         Me.tbbMakeHorizSpaceEqual.ImageIndex = 11
  336.         Me.tbbMakeHorizSpaceEqual.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  337.         Me.tbbMakeHorizSpaceEqual.Tag = "MakeHorizSpaceEqual"
  338.         Me.tbbMakeHorizSpaceEqual.ToolTipText = "MakeHorizSpaceEqual"
  339.         '
  340.         'tbbIncreaseHorizSpace
  341.         '
  342.         Me.tbbIncreaseHorizSpace.ImageIndex = 12
  343.         Me.tbbIncreaseHorizSpace.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  344.         Me.tbbIncreaseHorizSpace.Tag = "IncreaseHorizSpace"
  345.         Me.tbbIncreaseHorizSpace.ToolTipText = "IncreaseHorizSpace"
  346.         '
  347.         'tbbDecreaseHorizSpace
  348.         '
  349.         Me.tbbDecreaseHorizSpace.ImageIndex = 13
  350.         Me.tbbDecreaseHorizSpace.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  351.         Me.tbbDecreaseHorizSpace.Tag = "DecreaseHorizSpace"
  352.         Me.tbbDecreaseHorizSpace.ToolTipText = "DecreaseHorizSpace"
  353.         '
  354.         'tbbRemoveHorizSpace
  355.         '
  356.         Me.tbbRemoveHorizSpace.ImageIndex = 14
  357.         Me.tbbRemoveHorizSpace.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  358.         Me.tbbRemoveHorizSpace.Tag = "RemoveHorizSpace"
  359.         Me.tbbRemoveHorizSpace.ToolTipText = "RemoveHorizSpace"
  360.         '
  361.         'tbbLine5
  362.         '
  363.         Me.tbbLine5.Style = System.Windows.Forms.ToolBarButtonStyle.Separator
  364.         '
  365.         'tbbMakeVertSpaceEqual
  366.         '
  367.         Me.tbbMakeVertSpaceEqual.ImageIndex = 15
  368.         Me.tbbMakeVertSpaceEqual.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  369.         Me.tbbMakeVertSpaceEqual.Tag = "MakeVertSpaceEqual"
  370.         Me.tbbMakeVertSpaceEqual.ToolTipText = "MakeVertSpaceEqual"
  371.         '
  372.         'tbbIncreaseVertSpace
  373.         '
  374.         Me.tbbIncreaseVertSpace.ImageIndex = 16
  375.         Me.tbbIncreaseVertSpace.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  376.         Me.tbbIncreaseVertSpace.Tag = "IncreaseVertSpace"
  377.         Me.tbbIncreaseVertSpace.ToolTipText = "IncreaseVertSpace"
  378.         '
  379.         'tbbDecreaseVertSpace
  380.         '
  381.         Me.tbbDecreaseVertSpace.ImageIndex = 17
  382.         Me.tbbDecreaseVertSpace.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  383.         Me.tbbDecreaseVertSpace.Tag = "DecreaseVertSpace"
  384.         Me.tbbDecreaseVertSpace.ToolTipText = "DecreaseVertSpace"
  385.         '
  386.         'tbbRemoveVertSpace
  387.         '
  388.         Me.tbbRemoveVertSpace.ImageIndex = 18
  389.         Me.tbbRemoveVertSpace.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  390.         Me.tbbRemoveVertSpace.Tag = "RemoveVertSpace"
  391.         Me.tbbRemoveVertSpace.ToolTipText = "RemoveVertSpace"
  392.         '
  393.         'tbbLine6
  394.         '
  395.         Me.tbbLine6.Style = System.Windows.Forms.ToolBarButtonStyle.Separator
  396.         '
  397.         'tbbCenterHoriz
  398.         '
  399.         Me.tbbCenterHoriz.ImageIndex = 19
  400.         Me.tbbCenterHoriz.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  401.         Me.tbbCenterHoriz.Tag = "CenterHoriz"
  402.         Me.tbbCenterHoriz.ToolTipText = "CenterHoriz"
  403.         '
  404.         'tbbCenterVert
  405.         '
  406.         Me.tbbCenterVert.ImageIndex = 20
  407.         Me.tbbCenterVert.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  408.         Me.tbbCenterVert.Tag = "CenterVert"
  409.         Me.tbbCenterVert.ToolTipText = "CenterVert"
  410.         '
  411.         'tbbLine7
  412.         '
  413.         Me.tbbLine7.Style = System.Windows.Forms.ToolBarButtonStyle.Separator
  414.         '
  415.         'tbbBringToFront
  416.         '
  417.         Me.tbbBringToFront.ImageIndex = 21
  418.         Me.tbbBringToFront.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  419.         Me.tbbBringToFront.Tag = "BringToFront"
  420.         Me.tbbBringToFront.ToolTipText = "BringToFront"
  421.         '
  422.         'tbbSendToBack
  423.         '
  424.         Me.tbbSendToBack.ImageIndex = 22
  425.         Me.tbbSendToBack.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  426.         Me.tbbSendToBack.Tag = "SendToBack"
  427.         Me.tbbSendToBack.ToolTipText = "SendToBack"
  428.         '
  429.         'btnLoad
  430.         '
  431.         Me.btnLoad.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  432.         Me.btnLoad.Tag = "加载报表"
  433.         Me.btnLoad.Text = "加载报表"
  434.         '
  435.         'btnSave
  436.         '
  437.         Me.btnSave.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  438.         Me.btnSave.Tag = "保存报表"
  439.         Me.btnSave.Text = "保存报表"
  440.         '
  441.         'btnPrintview
  442.         '
  443.         Me.btnPrintview.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  444.         Me.btnPrintview.Tag = "报表预览"
  445.         Me.btnPrintview.Text = "报表预览"
  446.         '
  447.         'btnPrintSetup
  448.         '
  449.         Me.btnPrintSetup.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  450.         Me.btnPrintSetup.Tag = "打印设置"
  451.         Me.btnPrintSetup.Text = "打印设置"
  452.         '
  453.         'btnExit
  454.         '
  455.         Me.btnExit.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  456.         Me.btnExit.Tag = "退出"
  457.         Me.btnExit.Text = "退出"
  458.         '
  459.         'ImgLayout
  460.         '
  461.         Me.ImgLayout.ImageSize = New System.Drawing.Size(16, 16)
  462.         Me.ImgLayout.ImageStream = CType(resources.GetObject("ImgLayout.ImageStream"), System.Windows.Forms.ImageListStreamer)
  463.         Me.ImgLayout.TransparentColor = System.Drawing.Color.Transparent
  464.         '
  465.         'Panel1
  466.         '
  467.         Me.Panel1.Controls.Add(Me.tlbARToolbox)
  468.         Me.Panel1.Controls.Add(Me.Label1)
  469.         Me.Panel1.Dock = System.Windows.Forms.DockStyle.Left
  470.         Me.Panel1.Location = New System.Drawing.Point(0, 66)
  471.         Me.Panel1.Name = "Panel1"
  472.         Me.Panel1.Size = New System.Drawing.Size(125, 667)
  473.         Me.Panel1.TabIndex = 2
  474.         '
  475.         'tlbARToolbox
  476.         '
  477.         Me.tlbARToolbox.Appearance = System.Windows.Forms.ToolBarAppearance.Flat
  478.         Me.tlbARToolbox.Buttons.AddRange(New System.Windows.Forms.ToolBarButton() {Me.tbbPointer, Me.tbbLabel, Me.tbbTextBox, Me.tbbCheckBox, Me.tbbPicture, Me.tbbShape, Me.tbbLine, Me.tbbRichTextBox, Me.tbbSubreport, Me.tbbPageBreak, Me.tbbBarcode})
  479.         Me.tlbARToolbox.Divider = False
  480.         Me.tlbARToolbox.Dock = System.Windows.Forms.DockStyle.Fill
  481.         Me.tlbARToolbox.DropDownArrows = True
  482.         Me.tlbARToolbox.ImageList = Me.Imgtoolbox
  483.         Me.tlbARToolbox.Location = New System.Drawing.Point(0, 17)
  484.         Me.tlbARToolbox.Name = "tlbARToolbox"
  485.         Me.tlbARToolbox.ShowToolTips = True
  486.         Me.tlbARToolbox.Size = New System.Drawing.Size(125, 224)
  487.         Me.tlbARToolbox.TabIndex = 1
  488.         Me.tlbARToolbox.TextAlign = System.Windows.Forms.ToolBarTextAlign.Right
  489.         '
  490.         'tbbPointer
  491.         '
  492.         Me.tbbPointer.ImageIndex = 0
  493.         Me.tbbPointer.Tag = "Pointer"
  494.         Me.tbbPointer.Text = "Pointer"
  495.         Me.tbbPointer.ToolTipText = "Pointer"
  496.         '
  497.         'tbbLabel
  498.         '
  499.         Me.tbbLabel.ImageIndex = 1
  500.         Me.tbbLabel.Tag = "Label"
  501.         Me.tbbLabel.Text = "Label"
  502.         Me.tbbLabel.ToolTipText = "Label"
  503.         '
  504.         'tbbTextBox
  505.         '
  506.         Me.tbbTextBox.ImageIndex = 2
  507.         Me.tbbTextBox.Tag = "TextBox"
  508.         Me.tbbTextBox.Text = "TextBox"
  509.         Me.tbbTextBox.ToolTipText = "TextBox"
  510.         '
  511.         'tbbCheckBox
  512.         '
  513.         Me.tbbCheckBox.ImageIndex = 3
  514.         Me.tbbCheckBox.Tag = "CheckBox"
  515.         Me.tbbCheckBox.Text = "CheckBox"
  516.         Me.tbbCheckBox.ToolTipText = "CheckBox"
  517.         '
  518.         'tbbPicture
  519.         '
  520.         Me.tbbPicture.ImageIndex = 4
  521.         Me.tbbPicture.Tag = "Picture"
  522.         Me.tbbPicture.Text = "Picture"
  523.         Me.tbbPicture.ToolTipText = "Picture"
  524.         '
  525.         'tbbShape
  526.         '
  527.         Me.tbbShape.ImageIndex = 5
  528.         Me.tbbShape.Tag = "Shape"
  529.         Me.tbbShape.Text = "Shape"
  530.         Me.tbbShape.ToolTipText = "Shape"
  531.         '
  532.         'tbbLine
  533.         '
  534.         Me.tbbLine.ImageIndex = 6
  535.         Me.tbbLine.Tag = "Line"
  536.         Me.tbbLine.Text = "Line"
  537.         Me.tbbLine.ToolTipText = "Line"
  538.         '
  539.         'tbbRichTextBox
  540.         '
  541.         Me.tbbRichTextBox.ImageIndex = 7
  542.         Me.tbbRichTextBox.Tag = "RichText"
  543.         Me.tbbRichTextBox.Text = "RichTextBox"
  544.         Me.tbbRichTextBox.ToolTipText = "RichTextBox"
  545.         '
  546.         'tbbSubreport
  547.         '
  548.         Me.tbbSubreport.ImageIndex = 8
  549.         Me.tbbSubreport.Tag = "Subreport"
  550.         Me.tbbSubreport.Text = "Subreport"
  551.         Me.tbbSubreport.ToolTipText = "Subreport"
  552.         '
  553.         'tbbPageBreak
  554.         '
  555.         Me.tbbPageBreak.ImageIndex = 9
  556.         Me.tbbPageBreak.Tag = "PageBreak"
  557.         Me.tbbPageBreak.Text = "PageBreak"
  558.         Me.tbbPageBreak.ToolTipText = "PageBreak"
  559.         '
  560.         'tbbBarcode
  561.         '
  562.         Me.tbbBarcode.ImageIndex = 10
  563.         Me.tbbBarcode.Tag = "Barcode"
  564.         Me.tbbBarcode.Text = "Barcode"
  565.         Me.tbbBarcode.ToolTipText = "Barcode"
  566.         '
  567.         'Imgtoolbox
  568.         '
  569.         Me.Imgtoolbox.ImageSize = New System.Drawing.Size(16, 16)
  570.         Me.Imgtoolbox.ImageStream = CType(resources.GetObject("Imgtoolbox.ImageStream"), System.Windows.Forms.ImageListStreamer)
  571.         Me.Imgtoolbox.TransparentColor = System.Drawing.Color.Transparent
  572.         '
  573.         'Label1
  574.         '
  575.         Me.Label1.BackColor = System.Drawing.SystemColors.ControlDark
  576.         Me.Label1.Dock = System.Windows.Forms.DockStyle.Top
  577.         Me.Label1.ForeColor = System.Drawing.SystemColors.ControlLightLight
  578.         Me.Label1.Location = New System.Drawing.Point(0, 0)
  579.         Me.Label1.Name = "Label1"
  580.         Me.Label1.Size = New System.Drawing.Size(125, 17)
  581.         Me.Label1.TabIndex = 0
  582.         Me.Label1.Text = "ActiveReports"
  583.         '
  584.         'Panel2
  585.         '
  586.         Me.Panel2.Controls.Add(Me.Panel5)
  587.         Me.Panel2.Controls.Add(Me.Splitter2)
  588.         Me.Panel2.Controls.Add(Me.Panel4)
  589.         Me.Panel2.Dock = System.Windows.Forms.DockStyle.Right
  590.         Me.Panel2.Location = New System.Drawing.Point(856, 66)
  591.         Me.Panel2.Name = "Panel2"
  592.         Me.Panel2.Size = New System.Drawing.Size(172, 667)
  593.         Me.Panel2.TabIndex = 3
  594.         '
  595.         'Panel5
  596.         '
  597.         Me.Panel5.Controls.Add(Me.ReportExplorer1)
  598.         Me.Panel5.Dock = System.Windows.Forms.DockStyle.Fill
  599.         Me.Panel5.Location = New System.Drawing.Point(0, 0)
  600.         Me.Panel5.Name = "Panel5"
  601.         Me.Panel5.Size = New System.Drawing.Size(172, 556)
  602.         Me.Panel5.TabIndex = 2
  603.         '
  604.         'ReportExplorer1
  605.         '
  606.         Me.ReportExplorer1.Dock = System.Windows.Forms.DockStyle.Fill
  607.         Me.ReportExplorer1.Location = New System.Drawing.Point(0, 0)
  608.         Me.ReportExplorer1.Name = "ReportExplorer1"
  609.         Me.ReportExplorer1.ReportDesigner = Me.Designer1
  610.         Me.ReportExplorer1.Size = New System.Drawing.Size(172, 556)
  611.         Me.ReportExplorer1.TabIndex = 0
  612.         '
  613.         'Designer1
  614.         '
  615.         Me.Designer1.DesignUnits = DataDynamics.ActiveReports.Design.MeasurementUnits.US
  616.         Me.Designer1.Dock = System.Windows.Forms.DockStyle.Fill
  617.         Me.Designer1.DrawGrid = True
  618.         Me.Designer1.GridX = 16
  619.         Me.Designer1.GridY = 16
  620.         Me.Designer1.IsDirty = False
  621.         Me.Designer1.Location = New System.Drawing.Point(125, 66)
  622.         Me.Designer1.LockControls = False
  623.         Me.Designer1.Name = "Designer1"
  624.         Me.Designer1.ShowDataSourceIcon = True
  625.         Me.Designer1.Size = New System.Drawing.Size(727, 667)
  626.         Me.Designer1.SnapGrid = True
  627.         Me.Designer1.TabIndex = 5
  628.         Me.Designer1.ToolBoxItem = Nothing
  629.         '
  630.         'Splitter2
  631.         '
  632.         Me.Splitter2.Dock = System.Windows.Forms.DockStyle.Bottom
  633.         Me.Splitter2.Location = New System.Drawing.Point(0, 556)
  634.         Me.Splitter2.Name = "Splitter2"
  635.         Me.Splitter2.Size = New System.Drawing.Size(172, 3)
  636.         Me.Splitter2.TabIndex = 1
  637.         Me.Splitter2.TabStop = False
  638.         '
  639.         'Panel4
  640.         '
  641.         Me.Panel4.Controls.Add(Me.PropertyGrid1)
  642.         Me.Panel4.Dock = System.Windows.Forms.DockStyle.Bottom
  643.         Me.Panel4.Location = New System.Drawing.Point(0, 559)
  644.         Me.Panel4.Name = "Panel4"
  645.         Me.Panel4.Size = New System.Drawing.Size(172, 108)
  646.         Me.Panel4.TabIndex = 0
  647.         '
  648.         'PropertyGrid1
  649.         '
  650.         Me.PropertyGrid1.CommandsVisibleIfAvailable = True
  651.         Me.PropertyGrid1.Dock = System.Windows.Forms.DockStyle.Fill
  652.         Me.PropertyGrid1.LargeButtons = False
  653.         Me.PropertyGrid1.LineColor = System.Drawing.SystemColors.ScrollBar
  654.         Me.PropertyGrid1.Location = New System.Drawing.Point(0, 0)
  655.         Me.PropertyGrid1.Name = "PropertyGrid1"
  656.         Me.PropertyGrid1.Size = New System.Drawing.Size(172, 108)
  657.         Me.PropertyGrid1.TabIndex = 0
  658.         Me.PropertyGrid1.Text = "PropertyGrid1"
  659.         Me.PropertyGrid1.ViewBackColor = System.Drawing.SystemColors.Window
  660.         Me.PropertyGrid1.ViewForeColor = System.Drawing.SystemColors.WindowText
  661.         '
  662.         'Splitter1
  663.         '
  664.         Me.Splitter1.Dock = System.Windows.Forms.DockStyle.Right
  665.         Me.Splitter1.Location = New System.Drawing.Point(852, 66)
  666.         Me.Splitter1.Name = "Splitter1"
  667.         Me.Splitter1.Size = New System.Drawing.Size(4, 667)
  668.         Me.Splitter1.TabIndex = 4
  669.         Me.Splitter1.TabStop = False
  670.         '
  671.         'Panel3
  672.         '
  673.         Me.Panel3.Controls.Add(Me.tlbReport)
  674.         Me.Panel3.Controls.Add(Me.cmbFontSize)
  675.         Me.Panel3.Controls.Add(Me.cmbFonts)
  676.         Me.Panel3.Controls.Add(Me.cmbClassName)
  677.         Me.Panel3.Dock = System.Windows.Forms.DockStyle.Top
  678.         Me.Panel3.Location = New System.Drawing.Point(0, 41)
  679.         Me.Panel3.Name = "Panel3"
  680.         Me.Panel3.Size = New System.Drawing.Size(1028, 25)
  681.         Me.Panel3.TabIndex = 6
  682.         '
  683.         'tlbReport
  684.         '
  685.         Me.tlbReport.Appearance = System.Windows.Forms.ToolBarAppearance.Flat
  686.         Me.tlbReport.Buttons.AddRange(New System.Windows.Forms.ToolBarButton() {Me.tbbViewGrid, Me.tbbReorderGroups, Me.tbbLine8, Me.tbbEditScript, Me.tbbLine9, Me.tbbBold, Me.tbbItalic, Me.tbbUnderline, Me.tbbLine10, Me.tbbAlignLeft, Me.tbbCenter, Me.tbbAlignRight, Me.tbbJustify, Me.tbbLine11, Me.tbbBullets, Me.tbbDecreaseIndent, Me.tbbIncreaseIndent})
  687.         Me.tlbReport.Dock = System.Windows.Forms.DockStyle.Fill
  688.         Me.tlbReport.DropDownArrows = True
  689.         Me.tlbReport.ImageList = Me.ImgReport
  690.         Me.tlbReport.Location = New System.Drawing.Point(436, 0)
  691.         Me.tlbReport.Name = "tlbReport"
  692.         Me.tlbReport.ShowToolTips = True
  693.         Me.tlbReport.Size = New System.Drawing.Size(592, 28)
  694.         Me.tlbReport.TabIndex = 3
  695.         '
  696.         'tbbViewGrid
  697.         '
  698.         Me.tbbViewGrid.ImageIndex = 12
  699.         Me.tbbViewGrid.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  700.         Me.tbbViewGrid.Tag = "ViewGrid"
  701.         Me.tbbViewGrid.ToolTipText = "ViewGrid"
  702.         '
  703.         'tbbReorderGroups
  704.         '
  705.         Me.tbbReorderGroups.ImageIndex = 11
  706.         Me.tbbReorderGroups.Tag = "ReorderGroups"
  707.         Me.tbbReorderGroups.ToolTipText = "ReorderGroups"
  708.         '
  709.         'tbbLine8
  710.         '
  711.         Me.tbbLine8.Style = System.Windows.Forms.ToolBarButtonStyle.Separator
  712.         '
  713.         'tbbEditScript
  714.         '
  715.         Me.tbbEditScript.ImageIndex = 10
  716.         Me.tbbEditScript.Tag = "EditScript"
  717.         Me.tbbEditScript.ToolTipText = "EditScript"
  718.         '
  719.         'tbbLine9
  720.         '
  721.         Me.tbbLine9.Style = System.Windows.Forms.ToolBarButtonStyle.Separator
  722.         '
  723.         'tbbBold
  724.         '
  725.         Me.tbbBold.ImageIndex = 0
  726.         Me.tbbBold.Tag = "Bold"
  727.         Me.tbbBold.ToolTipText = "Bold"
  728.         '
  729.         'tbbItalic
  730.         '
  731.         Me.tbbItalic.ImageIndex = 1
  732.         Me.tbbItalic.Tag = "Italic"
  733.         Me.tbbItalic.ToolTipText = "Italic"
  734.         '
  735.         'tbbUnderline
  736.         '
  737.         Me.tbbUnderline.ImageIndex = 2
  738.         Me.tbbUnderline.Tag = "Underline"
  739.         Me.tbbUnderline.ToolTipText = "Underline"
  740.         '
  741.         'tbbLine10
  742.         '
  743.         Me.tbbLine10.Style = System.Windows.Forms.ToolBarButtonStyle.Separator
  744.         '
  745.         'tbbAlignLeft
  746.         '
  747.         Me.tbbAlignLeft.ImageIndex = 6
  748.         Me.tbbAlignLeft.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  749.         Me.tbbAlignLeft.Tag = "AlignLeft"
  750.         Me.tbbAlignLeft.ToolTipText = "AlignLeft"
  751.         '
  752.         'tbbCenter
  753.         '
  754.         Me.tbbCenter.ImageIndex = 7
  755.         Me.tbbCenter.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  756.         Me.tbbCenter.Tag = "Center"
  757.         Me.tbbCenter.ToolTipText = "Center"
  758.         '
  759.         'tbbAlignRight
  760.         '
  761.         Me.tbbAlignRight.ImageIndex = 8
  762.         Me.tbbAlignRight.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  763.         Me.tbbAlignRight.Tag = "AlignRight"
  764.         Me.tbbAlignRight.ToolTipText = "AlignRight"
  765.         '
  766.         'tbbJustify
  767.         '
  768.         Me.tbbJustify.ImageIndex = 9
  769.         Me.tbbJustify.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  770.         Me.tbbJustify.Tag = "Justify"
  771.         Me.tbbJustify.ToolTipText = "Justify"
  772.         '
  773.         'tbbLine11
  774.         '
  775.         Me.tbbLine11.Style = System.Windows.Forms.ToolBarButtonStyle.Separator
  776.         '
  777.         'tbbBullets
  778.         '
  779.         Me.tbbBullets.ImageIndex = 5
  780.         Me.tbbBullets.Style = System.Windows.Forms.ToolBarButtonStyle.ToggleButton
  781.         Me.tbbBullets.Tag = "Bullets"
  782.         Me.tbbBullets.ToolTipText = "Bullets"
  783.         '
  784.         'tbbDecreaseIndent
  785.         '
  786.         Me.tbbDecreaseIndent.ImageIndex = 4
  787.         Me.tbbDecreaseIndent.Tag = "DecreaseIndent"
  788.         Me.tbbDecreaseIndent.ToolTipText = "DecreaseIndent"
  789.         '
  790.         'tbbIncreaseIndent
  791.         '
  792.         Me.tbbIncreaseIndent.ImageIndex = 3
  793.         Me.tbbIncreaseIndent.Tag = "IncreaseIndent"
  794.         Me.tbbIncreaseIndent.ToolTipText = "IncreaseIndent"
  795.         '
  796.         'ImgReport
  797.         '
  798.         Me.ImgReport.ImageSize = New System.Drawing.Size(16, 16)
  799.         Me.ImgReport.ImageStream = CType(resources.GetObject("ImgReport.ImageStream"), System.Windows.Forms.ImageListStreamer)
  800.         Me.ImgReport.TransparentColor = System.Drawing.Color.Transparent
  801.         '
  802.         'cmbFontSize
  803.         '
  804.         Me.cmbFontSize.Dock = System.Windows.Forms.DockStyle.Left
  805.         Me.cmbFontSize.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList
  806.         Me.cmbFontSize.Location = New System.Drawing.Point(290, 0)
  807.         Me.cmbFontSize.Name = "cmbFontSize"
  808.         Me.cmbFontSize.Size = New System.Drawing.Size(146, 20)
  809.         Me.cmbFontSize.TabIndex = 2
  810.         '
  811.         'cmbFonts
  812.         '
  813.         Me.cmbFonts.Dock = System.Windows.Forms.DockStyle.Left
  814.         Me.cmbFonts.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList
  815.         Me.cmbFonts.Location = New System.Drawing.Point(145, 0)
  816.         Me.cmbFonts.Name = "cmbFonts"
  817.         Me.cmbFonts.Size = New System.Drawing.Size(145, 20)
  818.         Me.cmbFonts.TabIndex = 1
  819.         '
  820.         'cmbClassName
  821.         '
  822.         Me.cmbClassName.Dock = System.Windows.Forms.DockStyle.Left
  823.         Me.cmbClassName.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList
  824.         Me.cmbClassName.Location = New System.Drawing.Point(0, 0)
  825.         Me.cmbClassName.Name = "cmbClassName"
  826.         Me.cmbClassName.Size = New System.Drawing.Size(145, 20)
  827.         Me.cmbClassName.TabIndex = 0
  828.         '
  829.         'MainMenu1
  830.         '
  831.         Me.MainMenu1.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.mnuFile})
  832.         '
  833.         'mnuFile
  834.         '
  835.         Me.mnuFile.Index = 0
  836.         Me.mnuFile.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.mnuPrintPreview, Me.MenuItem4, Me.mnuLoadLayout, Me.mnuSaveLayout, Me.MenuItem7, Me.mnuPageSetup, Me.MenuItem10, Me.mnuExit})
  837.         Me.mnuFile.Text = "&File"
  838.         '
  839.         'mnuPrintPreview
  840.         '
  841.         Me.mnuPrintPreview.Index = 0
  842.         Me.mnuPrintPreview.Text = "&Print Preview"
  843.         '
  844.         'MenuItem4
  845.         '
  846.         Me.MenuItem4.Index = 1
  847.         Me.MenuItem4.Text = "-"
  848.         '
  849.         'mnuLoadLayout
  850.         '
  851.         Me.mnuLoadLayout.Index = 2
  852.         Me.mnuLoadLayout.Text = "&Load Layout"
  853.         '
  854.         'mnuSaveLayout
  855.         '
  856.         Me.mnuSaveLayout.Index = 3
  857.         Me.mnuSaveLayout.Text = "&Save Layout"
  858.         '
  859.         'MenuItem7
  860.         '
  861.         Me.MenuItem7.Index = 4
  862.         Me.MenuItem7.Text = "-"
  863.         '
  864.         'mnuPageSetup
  865.         '
  866.         Me.mnuPageSetup.Index = 5
  867.         Me.mnuPageSetup.Text = "Page Set&up"
  868.         '
  869.         'MenuItem10
  870.         '
  871.         Me.MenuItem10.Index = 6
  872.         Me.MenuItem10.Text = "-"
  873.         '
  874.         'mnuExit
  875.         '
  876.         Me.mnuExit.Index = 7
  877.         Me.mnuExit.Text = "E&xit"
  878.         '
  879.         'StartForm
  880.         '
  881.         Me.AutoScaleBaseSize = New System.Drawing.Size(6, 14)
  882.         Me.ClientSize = New System.Drawing.Size(1028, 733)
  883.         Me.Controls.Add(Me.Designer1)
  884.         Me.Controls.Add(Me.Splitter1)
  885.         Me.Controls.Add(Me.Panel2)
  886.         Me.Controls.Add(Me.Panel1)
  887.         Me.Controls.Add(Me.Panel3)
  888.         Me.Controls.Add(Me.tlbLayout)
  889.         Me.Menu = Me.MainMenu1
  890.         Me.Name = "StartForm"
  891.         Me.Text = "用户报表设计"
  892.         Me.WindowState = System.Windows.Forms.FormWindowState.Maximized
  893.         Me.Panel1.ResumeLayout(False)
  894.         Me.Panel2.ResumeLayout(False)
  895.         Me.Panel5.ResumeLayout(False)
  896.         Me.Panel4.ResumeLayout(False)
  897.         Me.Panel3.ResumeLayout(False)
  898.         Me.ResumeLayout(False)
  899.     End Sub
  900. #End Region
  901.     Protected Enum toolbarModes
  902.         singleControl
  903.         twoControls
  904.         multiControls
  905.         noControls
  906.     End Enum
  907.     Dim i As Integer
  908.     Dim cnt As Integer
  909.     Dim ctl As String
  910. #Region "fill comboboxes"
  911.     Private Sub fillFonts()
  912.         Me.cmbFonts.Items.Clear()
  913.         Dim fc As New System.Drawing.Text.InstalledFontCollection()
  914.         For i = 0 To fc.Families.Length - 1
  915.             Me.cmbFonts.Items.Add(fc.Families(i).Name)
  916.         Next
  917.         Me.cmbFonts.SelectedIndex = 0
  918.     End Sub
  919.     Private Sub fillFontSizes()
  920.         cmbFontSize.Items.Clear()
  921.         cmbFontSize.Items.Add(" 8")
  922.         cmbFontSize.Items.Add(" 9")
  923.         cmbFontSize.Items.Add("10")
  924.         cmbFontSize.Items.Add("11")
  925.         cmbFontSize.Items.Add("12")
  926.         cmbFontSize.Items.Add("14")
  927.         cmbFontSize.Items.Add("16")
  928.         cmbFontSize.Items.Add("18")
  929.         cmbFontSize.Items.Add("20")
  930.         cmbFontSize.Items.Add("22")
  931.         cmbFontSize.Items.Add("24")
  932.         cmbFontSize.Items.Add("26")
  933.         cmbFontSize.Items.Add("28")
  934.         cmbFontSize.Items.Add("36")
  935.         cmbFontSize.Items.Add("48")
  936.         cmbFontSize.Items.Add("72")
  937.         Me.cmbFontSize.SelectedIndex = 0
  938.     End Sub
  939.     Private Sub fillClassName()
  940.         Me.cmbClassName.Items.Clear()
  941.         For i = 0 To Designer1.Report.StyleSheet.Count - 1
  942.             Me.cmbClassName.Items.Add(Designer1.Report.StyleSheet(i).Name)
  943.         Next
  944.         Me.cmbClassName.SelectedIndex = 0
  945.     End Sub
  946. #End Region
  947.     Private Sub StartForm_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Load
  948.         Me.fillClassName()
  949.         Me.fillFonts()
  950.         Me.fillFontSizes()
  951.         Me.setModes(toolbarModes.noControls)
  952.         Me.Designer1.Focus()
  953.     End Sub
  954. #Region "Selection Changed Actions for the Report Toolbar"
  955.     Private Sub selChangeReportToolbar()
  956.         Dim m_arrayFont As New ArrayList()
  957.         Dim m_arrayFontSize As New ArrayList()
  958.         Dim m_arrayClassName As New ArrayList()
  959.         Dim sFont As String
  960.         Dim sFontSize As String
  961.         Dim sClassName As String
  962.         sFont = ""
  963.         sFontSize = ""
  964.         sClassName = ""
  965.         Dim ctl As String
  966.         cnt = Designer1.Selection.Count
  967.         If cnt = 0 Then
  968.             Exit Sub
  969.         End If
  970.         For i = 0 To cnt - 1
  971.             ctl = Designer1.Selection(i).GetType().ToString
  972.             If ((ctl.IndexOf("TextBox") > 0) Or (ctl.IndexOf("CheckBox") > 0) Or (ctl.IndexOf("Label") > 0)) Then
  973.                 Select Case ctl
  974.                     Case "DataDynamics.ActiveReports.TextBox"
  975.                         sFont = CType(Designer1.Selection(i), DataDynamics.ActiveReports.TextBox).Font.Name.ToString()
  976.                         sFontSize = CType(Designer1.Selection(i), DataDynamics.ActiveReports.TextBox).Font.Size.ToString()
  977.                         sClassName = CType(Designer1.Selection(i), DataDynamics.ActiveReports.TextBox).ClassName.ToString()
  978.                         If m_arrayFont.Contains(sFont) = False Then
  979.                             m_arrayFont.Add(sFont)
  980.                             If m_arrayFontSize.Contains(sFontSize) = False Then
  981.                                 m_arrayFontSize.Add(sFontSize)
  982.                                 If m_arrayClassName.Contains(sClassName) = False Then
  983.                                     m_arrayClassName.Add(sClassName)
  984.                                 End If
  985.                             End If
  986.                         End If
  987.                     Case "DataDynamics.ActiveReports.Label"
  988.                         sFont = CType(Designer1.Selection(i), DataDynamics.ActiveReports.Label).Font.Name.ToString()
  989.                         sFontSize = CType(Designer1.Selection(i), DataDynamics.ActiveReports.Label).Font.Size.ToString()
  990.                         sClassName = CType(Designer1.Selection(i), DataDynamics.ActiveReports.Label).ClassName.ToString()
  991.                         If m_arrayFont.Contains(sFont) = False Then
  992.                             m_arrayFont.Add(sFont)
  993.                             If m_arrayFontSize.Contains(sFontSize) = False Then
  994.                                 m_arrayFontSize.Add(sFontSize)
  995.                                 If m_arrayClassName.Contains(sClassName) = False Then
  996.                                     m_arrayClassName.Add(sClassName)
  997.                                 End If
  998.                             End If
  999.                         End If
  1000.                     Case "DataDynamics.ActiveReports.CheckBox"
  1001.                         sFont = CType(Designer1.Selection(i), DataDynamics.ActiveReports.CheckBox).Font.Name
  1002.                         sFontSize = CType(Designer1.Selection(i), DataDynamics.ActiveReports.CheckBox).Font.Size
  1003.                         sClassName = CType(Designer1.Selection(i), DataDynamics.ActiveReports.CheckBox).ClassName
  1004.                         If m_arrayFont.Contains(sFont) = False Then
  1005.                             m_arrayFont.Add(sFont)
  1006.                             If m_arrayFontSize.Contains(sFontSize) = False Then
  1007.                                 m_arrayFontSize.Add(sFontSize)
  1008.                                 If m_arrayClassName.Contains(sClassName) = False Then
  1009.                                     m_arrayClassName.Add(sClassName)
  1010.                                 End If
  1011.                             End If
  1012.                         End If
  1013.                 End Select
  1014.             End If
  1015.         Next
  1016.         If ((m_arrayFont.Count >= 1) AndAlso (cnt > 1)) Then
  1017.             cmbFonts.Text = ""
  1018.             cmbFonts.Enabled = True
  1019.         ElseIf (m_arrayFont.Count = 0) Then
  1020.             cmbFonts.Text = ""
  1021.             cmbFonts.Enabled = False
  1022.         ElseIf (m_arrayFont.Count = 1) Then
  1023.             cmbFonts.Text = m_arrayFont(0).ToString()
  1024.             cmbFonts.Enabled = True
  1025.         End If
  1026.         If ((m_arrayFont.Count >= 1) AndAlso (cnt > 1)) Then
  1027.             cmbFontSize.Text = ""
  1028.             cmbFontSize.Enabled = True
  1029.         ElseIf (m_arrayFontSize.Count = 0) Then
  1030.             cmbFontSize.Text = ""
  1031.             cmbFontSize.Enabled = False
  1032.         ElseIf (m_arrayFontSize.Count = 1) Then
  1033.             cmbFontSize.Text = m_arrayFontSize(0).ToString()
  1034.             cmbFontSize.Enabled = True
  1035.         End If
  1036.         If ((m_arrayFont.Count >= 1) AndAlso (cnt > 1)) Then
  1037.             cmbClassName.Text = ""
  1038.             cmbClassName.Enabled = True
  1039.         ElseIf (m_arrayClassName.Count = 0) Then
  1040.             cmbClassName.Text = ""
  1041.             cmbClassName.Enabled = False
  1042.         ElseIf (m_arrayClassName.Count = 1) Then
  1043.             cmbClassName.Text = m_arrayClassName(0).ToString()
  1044.             cmbClassName.Enabled = True
  1045.         End If
  1046.     End Sub
  1047. #End Region
  1048. #Region "Selection Changed Actions for the Layout Toolbar"
  1049.     Private Sub selChangeLayoutToolbar()
  1050.         cnt = Me.Designer1.Selection.Count
  1051.         If cnt = 0 Then
  1052.             Me.setModes(toolbarModes.noControls)
  1053.         ElseIf ((cnt = 1) AndAlso ((Me.Designer1.Selection(0).GetType().BaseType.ToString() <> "DataDynamics.ActiveReports.Section") AndAlso (Me.Designer1.Selection(0).GetType().BaseType.ToString() <> "System.Object"))) Then
  1054.             Me.setModes(toolbarModes.singleControl)
  1055.         ElseIf (cnt = 2) Then
  1056.             Me.setModes(toolbarModes.twoControls)
  1057.         ElseIf (cnt > 2) Then
  1058.             Me.setModes(toolbarModes.multiControls)
  1059.         End If
  1060.     End Sub
  1061. #End Region
  1062. #Region "Selection Changed Actions for the Property Grid"
  1063.     Private Sub selChangePropGrid()
  1064.         cnt = Me.Designer1.Selection.Count - 1
  1065.         Dim selectedControls(cnt) As Object
  1066.         Try
  1067.             For i = 0 To Me.Designer1.Selection.Count - 1
  1068.                 selectedControls.SetValue(CType(Me.Designer1.Selection(i), Object), i)
  1069.             Next
  1070.             Me.PropertyGrid1.SelectedObjects = selectedControls
  1071.         Catch ex As Exception
  1072.             MessageBox.Show(Me, ex.Message + ": " + ex.Source + ": " + ex.StackTrace, "Selection Error", MessageBoxButtons.OK, MessageBoxIcon.Error)
  1073.         End Try
  1074.     End Sub
  1075. #End Region
  1076.     Private Sub tlbARToolbox_ButtonClick(ByVal sender As System.Object, ByVal e As System.Windows.Forms.ToolBarButtonClickEventArgs) Handles tlbARToolbox.ButtonClick
  1077.         If (e.Button.Tag.ToString() <> "Pointer") Then
  1078.             Designer1.ToolBoxItem = e.Button.Tag.ToString()
  1079.         Else
  1080.             Designer1.ToolBoxItem = Nothing
  1081.         End If
  1082.     End Sub
  1083.     Private Sub tlbReport_ButtonClick(ByVal sender As Object, ByVal e As System.Windows.Forms.ToolBarButtonClickEventArgs) Handles tlbReport.ButtonClick
  1084.         executeReportAction(e.Button.Tag.ToString(), e)
  1085.     End Sub
  1086. #Region "Execute Report Action method for tlbReport"
  1087.     Private Sub executeReportAction(ByVal action As String, ByVal e As System.Windows.Forms.ToolBarButtonClickEventArgs)
  1088.         Try
  1089.             Select Case action
  1090.                 Case "Bold"
  1091.                     Designer1.ExecuteAction(DesignerAction.FormatFontBold)
  1092.                 Case "Italic"
  1093.                     Designer1.ExecuteAction(DesignerAction.FormatFontItalic)
  1094.                 Case "Underline"
  1095.                     Designer1.ExecuteAction(DesignerAction.FormatFontUnderline)
  1096.                 Case "AlignRight"
  1097.                     Designer1.ExecuteAction(DesignerAction.FormatTextAlignRight)
  1098.                 Case "Center"
  1099.                     Designer1.ExecuteAction(DesignerAction.FormatTextAlignCenter)
  1100.                 Case "AlignLeft"
  1101.                     Designer1.ExecuteAction(DesignerAction.FormatTextAlignLeft)
  1102.                 Case "Justify"
  1103.                     Designer1.ExecuteAction(DesignerAction.FormatTextAlignJustify)
  1104.                 Case "Bullets"
  1105.                     Designer1.ExecuteAction(DesignerAction.FormatRTFBullets)
  1106.                 Case "DecreaseIndent"
  1107.                     Designer1.ExecuteAction(DesignerAction.FormatRTFOutdent)
  1108.                 Case "IncreaseIndent"
  1109.                     Designer1.ExecuteAction(DesignerAction.FormatRTFIndent)
  1110.                 Case "EditScript"
  1111.                     Designer1.ExecuteAction(DesignerAction.EditScript)
  1112.                 
  1113.             End Select
  1114.         Catch ex As Exception
  1115.             MessageBox.Show(Me, ex.Message, "Action Failed", MessageBoxButtons.OK, MessageBoxIcon.Error)
  1116.         End Try
  1117.     End Sub
  1118. #End Region
  1119.     Private Sub cmbFonts_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles cmbFonts.SelectedIndexChanged
  1120.         If cmbFonts.Text <> "" Then
  1121.             setFont()
  1122.         End If
  1123.     End Sub
  1124.     Private Sub cmbFontSize_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles cmbFontSize.SelectedIndexChanged
  1125.         If cmbFontSize.Text <> "" Then
  1126.             setFont()
  1127.         End If
  1128.     End Sub
  1129.     Private Sub cmbClassName_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles cmbClassName.SelectedIndexChanged
  1130.         If cmbClassName.Text <> "" Then
  1131.             setClassName()
  1132.         End If
  1133.     End Sub
  1134. #Region "Adjusts texts in the ComboBoxes"
  1135.     Private Sub setFont()
  1136.         For i = 0 To i < Designer1.Selection.Count - 1
  1137.             ctl = Designer1.Selection(i).GetType.ToString()
  1138.             If ((ctl.IndexOf("TextBox") > 0) Or (ctl.IndexOf("CheckBox") > 0) Or (ctl.IndexOf("Label") > 0)) Then
  1139.                 Select Case ctl
  1140.                     Case "DataDynamics.ActiveReports.TextBox"
  1141.                         If cmbFontSize.Text <> "" Then
  1142.                             CType(Designer1.Selection(i), DataDynamics.ActiveReports.TextBox).Font = New Font(cmbFonts.Text, (Long.Parse(cmbFontSize.Text)))
  1143.                         Else
  1144.                             CType(Designer1.Selection(i), DataDynamics.ActiveReports.TextBox).Font = New Font(cmbFonts.Text, (Long.Parse(Font.Size.ToString)))
  1145.                         End If
  1146.                     Case "DataDynamics.ActiveReports.Label"
  1147.                         If cmbFontSize.Text <> "" Then
  1148.                             CType(Designer1.Selection(i), DataDynamics.ActiveReports.Label).Font = New Font(cmbFonts.Text, (Long.Parse(cmbFontSize.Text)))
  1149.                         Else
  1150.                             CType(Designer1.Selection(i), DataDynamics.ActiveReports.Label).Font = New Font(cmbFonts.Text, (Long.Parse(Font.Size.ToString)))
  1151.                         End If
  1152.                     Case "DataDynamics.ActiveReports.CheckBox"
  1153.                         If cmbFontSize.Text <> "" Then
  1154.                             CType(Designer1.Selection(i), DataDynamics.ActiveReports.CheckBox).Font = New Font(cmbFonts.Text, (Long.Parse(cmbFontSize.Text)))
  1155.                         Else
  1156.                             CType(Designer1.Selection(i), DataDynamics.ActiveReports.CheckBox).Font = New Font(cmbFonts.Text, (Long.Parse(Font.Size.ToString)))
  1157.                         End If
  1158.                 End Select
  1159.             End If
  1160.         Next
  1161.     End Sub
  1162.     Private Sub setClassName()
  1163.         For i = 0 To i < Designer1.Selection.Count - 1
  1164.             ctl = Designer1.Selection(i).GetType.ToString()
  1165.             If ctl.IndexOf("TextBox") > 0 Or ctl.IndexOf("CheckBox") > 0 Or ctl.IndexOf("Label") > 0 Then
  1166.                 Select Case ctl
  1167.                     Case "DataDynamics.ActiveReports.TextBox"
  1168.                         CType(Designer1.Selection(i), DataDynamics.ActiveReports.TextBox).ClassName = cmbClassName.Text
  1169.                     Case "DataDynamics.ActiveReports.Label"
  1170.                         CType(Designer1.Selection(i), DataDynamics.ActiveReports.Label).ClassName = cmbClassName.Text
  1171.                     Case "DataDynamics.ActiveReports.CheckBox"
  1172.                         CType(Designer1.Selection(i), DataDynamics.ActiveReports.CheckBox).ClassName = cmbClassName.Text
  1173.                 End Select
  1174.             End If
  1175.         Next
  1176.     End Sub
  1177. #End Region
  1178.     Private Sub Designer1_StatusChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles Designer1.StatusChanged
  1179.         For i = 0 To Me.tlbReport.Buttons.Count - 1
  1180.             Dim tb As New System.Windows.Forms.ToolBarButton()
  1181.             tb = Me.tlbReport.Buttons(i)
  1182.             If tb.Tag Is Nothing = False Then
  1183.                 setStatus(tb.Tag, tb)
  1184.             End If
  1185.         Next
  1186.     End Sub
  1187.     Private Sub setStatus(ByVal action As String, ByVal toolbutton As System.Windows.Forms.ToolBarButton)
  1188.         Dim m_action As New DataDynamics.ActiveReports.Design.DesignerAction()
  1189.         m_action = getActionFromString(action)
  1190.         toolbutton.Enabled = Designer1.QueryActionEnabled(m_action)
  1191.         toolbutton.Pushed = Designer1.QueryActionChecked(m_action)
  1192.     End Sub
  1193. #Region "Designer Action returned for string value of action in function (tlbReport)"
  1194.     Private Function getActionFromString(ByVal action As String) As DataDynamics.ActiveReports.Design.DesignerAction
  1195.         Dim m_action As New DataDynamics.ActiveReports.Design.DesignerAction()
  1196.         Select Case (action)
  1197.             Case "Bold"
  1198.                 m_action = DesignerAction.FormatFontBold
  1199.             Case "Italic"
  1200.                 m_action = DesignerAction.FormatFontItalic
  1201.             Case "Underline"
  1202.                 m_action = DesignerAction.FormatFontUnderline
  1203.             Case "Bullets"
  1204.                 m_action = DesignerAction.FormatRTFBullets
  1205.             Case "IncreaseIndent"
  1206.                 m_action = DesignerAction.FormatRTFIndent
  1207.             Case "DecreaseIndent"
  1208.                 m_action = DesignerAction.FormatRTFOutdent
  1209.             Case "EditScript"
  1210.                 m_action = DesignerAction.EditScript
  1211.             Case "ReorderGroups"
  1212.                 m_action = DesignerAction.ReorderGroups
  1213.             Case "ViewGrid"
  1214.                 m_action = DesignerAction.ViewGrid
  1215.             Case "AlignLeft"
  1216.                 m_action = DesignerAction.FormatTextAlignLeft
  1217.             Case "Center"
  1218.                 m_action = DesignerAction.FormatTextAlignCenter
  1219.             Case "AlignRight"
  1220.                 m_action = DesignerAction.FormatTextAlignRight
  1221.             Case "Justify"
  1222.                 m_action = DesignerAction.FormatTextAlignJustify
  1223.         End Select
  1224.         Return m_action
  1225.     End Function
  1226. #End Region
  1227. #Region "Sets the Mode for tlbLayout"
  1228.     'Layout Toolbar stuff
  1229.     Private Sub setModes(ByVal tbModes As StartForm.toolbarModes)
  1230.         Me.SuspendLayout()
  1231.         Select Case tbModes
  1232.             Case toolbarModes.multiControls
  1233.                 Me.tbbAlignBottoms.Enabled = True
  1234.                 Me.tbbAlignCenters.Enabled = True
  1235.                 Me.tbbAlignLefts.Enabled = True
  1236.                 Me.tbbAlignMiddles.Enabled = True
  1237.                 Me.tbbAlignRights.Enabled = True
  1238.                 Me.tbbAligntoGrid.Enabled = True
  1239.                 Me.tbbAlignTops.Enabled = True
  1240.                 Me.tbbBringToFront.Enabled = True
  1241.                 Me.tbbCenterHoriz.Enabled = True
  1242.                 Me.tbbCenterVert.Enabled = True
  1243.                 Me.tbbDecreaseHorizSpace.Enabled = True
  1244.                 Me.tbbDecreaseVertSpace.Enabled = True
  1245.                 Me.tbbIncreaseHorizSpace.Enabled = True
  1246.                 Me.tbbIncreaseVertSpace.Enabled = True
  1247.                 Me.tbbMakeHorizSpaceEqual.Enabled = True
  1248.                 Me.tbbMakeSameHeight.Enabled = True
  1249.                 Me.tbbMakeSameSize.Enabled = True
  1250.                 Me.tbbMakeSameWidth.Enabled = True
  1251.                 Me.tbbMakeVertSpaceEqual.Enabled = True
  1252.                 Me.tbbRemoveHorizSpace.Enabled = True
  1253.                 Me.tbbRemoveVertSpace.Enabled = True
  1254.                 Me.tbbSendToBack.Enabled = True
  1255.                 Me.tbbSizeToGrid.Enabled = True
  1256.             Case toolbarModes.twoControls
  1257.                 Me.tbbAlignBottoms.Enabled = True
  1258.                 Me.tbbAlignCenters.Enabled = True
  1259.                 Me.tbbAlignLefts.Enabled = True
  1260.                 Me.tbbAlignMiddles.Enabled = True
  1261.                 Me.tbbAlignRights.Enabled = True
  1262.                 Me.tbbAligntoGrid.Enabled = True
  1263.                 Me.tbbAlignTops.Enabled = True
  1264.                 Me.tbbBringToFront.Enabled = True
  1265.                 Me.tbbCenterHoriz.Enabled = True
  1266.                 Me.tbbCenterVert.Enabled = True
  1267.                 Me.tbbDecreaseHorizSpace.Enabled = False
  1268.                 Me.tbbDecreaseVertSpace.Enabled = False
  1269.                 Me.tbbIncreaseHorizSpace.Enabled = False
  1270.                 Me.tbbIncreaseVertSpace.Enabled = False
  1271.                 Me.tbbMakeHorizSpaceEqual.Enabled = False
  1272.                 Me.tbbMakeSameHeight.Enabled = True
  1273.                 Me.tbbMakeSameWidth.Enabled = True
  1274.                 Me.tbbMakeSameSize.Enabled = True
  1275.                 Me.tbbMakeVertSpaceEqual.Enabled = False
  1276.                 Me.tbbRemoveHorizSpace.Enabled = True
  1277.                 Me.tbbRemoveVertSpace.Enabled = True
  1278.                 Me.tbbSendToBack.Enabled = True
  1279.                 Me.tbbSizeToGrid.Enabled = True
  1280.             Case toolbarModes.singleControl
  1281.                 Me.tbbAlignBottoms.Enabled = False
  1282.                 Me.tbbAlignCenters.Enabled = False
  1283.                 Me.tbbAlignLefts.Enabled = False
  1284.                 Me.tbbAlignMiddles.Enabled = False
  1285.                 Me.tbbAlignRights.Enabled = False
  1286.                 Me.tbbAligntoGrid.Enabled = True
  1287.                 Me.tbbAlignTops.Enabled = False
  1288.                 Me.tbbCenterHoriz.Enabled = True
  1289.                 Me.tbbCenterVert.Enabled = True
  1290.                 Me.tbbDecreaseVertSpace.Enabled = False
  1291.                 Me.tbbIncreaseVertSpace.Enabled = False
  1292.                 Me.tbbDecreaseHorizSpace.Enabled = False
  1293.                 Me.tbbIncreaseHorizSpace.Enabled = False
  1294.                 Me.tbbMakeHorizSpaceEqual.Enabled = False
  1295.                 Me.tbbMakeSameHeight.Enabled = False
  1296.                 Me.tbbMakeSameSize.Enabled = False
  1297.                 Me.tbbMakeSameWidth.Enabled = False
  1298.                 Me.tbbMakeVertSpaceEqual.Enabled = False
  1299.                 Me.tbbRemoveHorizSpace.Enabled = False
  1300.                 Me.tbbRemoveVertSpace.Enabled = False
  1301.                 Me.tbbSendToBack.Enabled = True
  1302.                 Me.tbbSizeToGrid.Enabled = True
  1303.                 Me.tbbBringToFront.Enabled = True
  1304.             Case toolbarModes.noControls
  1305.                 Me.tbbAlignBottoms.Enabled = False
  1306.                 Me.tbbAlignCenters.Enabled = False
  1307.                 Me.tbbAlignLefts.Enabled = False
  1308.                 Me.tbbAlignMiddles.Enabled = False
  1309.                 Me.tbbAlignRights.Enabled = False
  1310.                 Me.tbbAligntoGrid.Enabled = False
  1311.                 Me.tbbAlignTops.Enabled = False
  1312.                 Me.tbbBringToFront.Enabled = False
  1313.                 Me.tbbCenterHoriz.Enabled = False
  1314.                 Me.tbbCenterVert.Enabled = False
  1315.                 Me.tbbDecreaseHorizSpace.Enabled = False
  1316.                 Me.tbbDecreaseVertSpace.Enabled = False
  1317.                 Me.tbbIncreaseHorizSpace.Enabled = False
  1318.                 Me.tbbIncreaseVertSpace.Enabled = False
  1319.                 Me.tbbMakeHorizSpaceEqual.Enabled = False
  1320.                 Me.tbbMakeSameHeight.Enabled = False
  1321.                 Me.tbbMakeSameSize.Enabled = False
  1322.                 Me.tbbMakeSameWidth.Enabled = False
  1323.                 Me.tbbMakeVertSpaceEqual.Enabled = False
  1324.                 Me.tbbRemoveHorizSpace.Enabled = False
  1325.                 Me.tbbRemoveVertSpace.Enabled = False
  1326.                 Me.tbbSendToBack.Enabled = False
  1327.                 Me.tbbSizeToGrid.Enabled = False
  1328.         End Select
  1329.         Me.ResumeLayout()
  1330.     End Sub
  1331. #End Region
  1332.     Private Sub tlbLayout_ButtonClick(ByVal sender As Object, ByVal e As System.Windows.Forms.ToolBarButtonClickEventArgs) Handles tlbLayout.ButtonClick
  1333.         Me.executeLayoutAction(e.Button.Tag.ToString())
  1334.       
  1335.     End Sub
  1336. #Region "Execute action code for tlbLayout"
  1337.     Private Sub executeLayoutAction(ByVal actionTool As String)
  1338.         Select Case actionTool
  1339.             Case "BringToFront"
  1340.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatOrderBringToFront)
  1341.             Case "SendToBack"
  1342.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatOrderSendToBack)
  1343.             Case "MakeSameHeight"
  1344.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatSizeSameHeight)
  1345.             Case "MakeSameWidth"
  1346.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatSizeSameWidth)
  1347.             Case "MakeSameSize"
  1348.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatSizeBoth)
  1349.             Case "AlignTops"
  1350.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatAlignTop)
  1351.             Case "AlignBottoms"
  1352.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatAlignBottom)
  1353.             Case "AlignLefts"
  1354.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatAlignLeft)
  1355.             Case "AlignRights"
  1356.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatAlignRight)
  1357.             Case "AlignMiddles"
  1358.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatAlignMiddle)
  1359.             Case "AlignCenters"
  1360.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatAlignCenter)
  1361.             Case "SizeToGrid"
  1362.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.SnapToGrid)
  1363.             Case "MakeHorizSpaceEqual"
  1364.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatSpaceEquallyHorizontal)
  1365.             Case "IncreaseHorizSpace"
  1366.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatSpaceIncreaseHorizontal)
  1367.             Case "DecreaseHorizSpace"
  1368.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatSpaceDecreaseHorizontal)
  1369.             Case "MakeVertSpaceEqual"
  1370.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatSpaceEquallyVertical)
  1371.             Case "IncreaseVertSpace"
  1372.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatSpaceIncreaseVertical)
  1373.             Case "DecreaseVertSpace"
  1374.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatSpaceDecreaseVertical)
  1375.             Case "CenterHoriz"
  1376.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatCenterHorizontally)
  1377.             Case "CenterVert"
  1378.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatCenterVertically)
  1379.             Case "RemoveHorizSpace"
  1380.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatSpaceRemoveHorizontal)
  1381.             Case "RemoveVertSpace"
  1382.                 Me.Designer1.ExecuteAction(DataDynamics.ActiveReports.Design.DesignerAction.FormatSpaceRemoveVertical)
  1383.             Case "加载报表"
  1384.                 Me.Designer1.ExecuteAction(DesignerAction.FileOpen)
  1385.             Case "保存报表"
  1386.                 Me.Designer1.ExecuteAction(DesignerAction.FileSave)
  1387.             Case "报表预览"
  1388.                 Dim rpt As New DataDynamics.ActiveReports.ActiveReport
  1389.                 Dim m_stream As New System.IO.MemoryStream
  1390.                 Me.Designer1.Report.SaveLayout(m_stream)
  1391.                 m_stream.Position = 0
  1392.                 rpt.LoadLayout(m_stream)
  1393.                 m_stream.Close()
  1394.                 Dim frm As New frmViewer
  1395.                 frm.SetReport(rpt)
  1396.                 frm.ShowDialog(Me)
  1397.             Case "打印设置"
  1398.                 Me.Designer1.ExecuteAction(DesignerAction.ReportSettings)
  1399.             Case "退出"
  1400.                 Me.Close()
  1401.         End Select
  1402.     End Sub
  1403. #End Region
  1404.     'Menu actions code
  1405.     Private Sub mnuPrintPreview_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles mnuPrintPreview.Click
  1406.         Dim rpt As New DataDynamics.ActiveReports.ActiveReport()
  1407.         Dim m_stream As New System.IO.MemoryStream()
  1408.         Me.Designer1.Report.SaveLayout(m_stream)
  1409.         m_stream.Position = 0
  1410.         rpt.LoadLayout(m_stream)
  1411.         m_stream.Close()
  1412.         Dim frm As New frmViewer()
  1413.         frm.SetReport(rpt)
  1414.         frm.ShowDialog(Me)
  1415.     End Sub
  1416.     Private Sub mnuLoadLayout_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles mnuLoadLayout.Click
  1417.         Me.Designer1.ExecuteAction(DesignerAction.FileOpen)
  1418.     End Sub
  1419.     Private Sub mnuSaveLayout_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles mnuSaveLayout.Click
  1420.         Me.Designer1.ExecuteAction(DesignerAction.FileSave)
  1421.     End Sub
  1422.     Private Sub mnuPageSetup_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles mnuPageSetup.Click
  1423.         Me.Designer1.ExecuteAction(DesignerAction.ReportSettings)
  1424.     End Sub
  1425.     Private Sub mnuExit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles mnuExit.Click
  1426.         Me.Close()
  1427.     End Sub
  1428.     Private Sub Designer1_SelectionChanged() Handles Designer1.SelectionChanged
  1429.         selChangeReportToolbar()
  1430.         selChangeLayoutToolbar()
  1431.         selChangePropGrid()
  1432.     End Sub
  1433.     Private Sub Designer1_SystemColorsChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles Designer1.SystemColorsChanged
  1434.     End Sub
  1435.     Private Sub Designer1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Designer1.Load
  1436.     End Sub
  1437. End Class