This repository has been archived by the owner on Sep 11, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Form1.vb
54 lines (48 loc) · 1.76 KB
/
Form1.vb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
Imports Microsoft.VisualBasic
Imports System
Imports System.Collections.Generic
Imports System.ComponentModel
Imports System.Data
Imports System.Drawing
Imports System.Text
Imports System.Windows.Forms
Imports DevExpress.XtraScheduler
Imports DevExpress.XtraScheduler.Reporting
Imports DevExpress.XtraScheduler.Reporting.UI
Imports DevExpress.XtraPrinting
Imports DevExpress.XtraPrinting.Control
Imports DevExpress.XtraPrinting.Drawing
Imports DevExpress.XtraReports.UI
Imports DevExpress.XtraScheduler.Design
Imports DevExpress.XtraScheduler.Localization
Namespace HorizontalResourceHeaderCaption
Partial Public Class Form1
Inherits Form
Public Sub New()
InitializeComponent()
Dim res1 As Resource = schedulerStorage1.CreateResource(1)
res1.Caption = "Peter Dolan"
Dim res2 As Resource = schedulerStorage1.CreateResource(2)
res2.Caption = "Ryan Fischer"
Dim res3 As Resource = schedulerStorage1.CreateResource(3)
res3.Caption = "Andrew Miller"
Dim res4 As Resource = schedulerStorage1.CreateResource(4)
res4.Caption = "Tom Hamlett"
Dim res5 As Resource = schedulerStorage1.CreateResource(5)
res5.Caption = "Jerry Campbell"
schedulerStorage1.Resources.AddRange(New Resource() { res1, res2, res3, res4, res5 })
End Sub
Private Sub button1_Click(ByVal sender As Object, ByVal e As EventArgs) Handles button1.Click
CreateReport().ShowPreview()
End Sub
Private Sub button2_Click(ByVal sender As Object, ByVal e As EventArgs) Handles button2.Click
Dim tool As New SchedulerReportDesignTool(CreateReport())
tool.ShowDesignerDialog()
End Sub
Private Function CreateReport() As WeeklyReport
Dim rpt As New WeeklyReport()
rpt.SchedulerAdapter.SetSourceObject(Me.schedulerControl1)
Return rpt
End Function
End Class
End Namespace