DocumentViewer: Add FileLoaded Property

This commit is contained in:
Jonathan Jenne 2021-01-06 16:55:33 +01:00
parent 59e925d6b2
commit cf8bbee545
7 changed files with 118 additions and 704 deletions

View File

@ -49,10 +49,10 @@ Partial Class DocumentViewer
Me.barDockControlBottom = New DevExpress.XtraBars.BarDockControl()
Me.barDockControlLeft = New DevExpress.XtraBars.BarDockControl()
Me.barDockControlRight = New DevExpress.XtraBars.BarDockControl()
Me.BarStaticItem1 = New DevExpress.XtraBars.BarStaticItem()
Me.RepositoryItemTextEdit1 = New DevExpress.XtraEditors.Repository.RepositoryItemTextEdit()
Me.SpreadsheetControl1 = New DevExpress.XtraSpreadsheet.SpreadsheetControl()
Me.PrintDocument1 = New System.Drawing.Printing.PrintDocument()
Me.BarStaticItem1 = New DevExpress.XtraBars.BarStaticItem()
CType(Me.BarManager1, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.RepositoryItemTextEdit2, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.RepositoryItemTextEdit1, System.ComponentModel.ISupportInitialize).BeginInit()
@ -63,6 +63,7 @@ Partial Class DocumentViewer
Me.GdViewer.AllowDropFile = False
Me.GdViewer.AnimateGIF = True
Me.GdViewer.AnnotationDropShadow = False
Me.GdViewer.AnnotationEnableMultiSelect = True
Me.GdViewer.AnnotationResizeRotateHandlesColor = System.Drawing.Color.FromArgb(CType(CType(0, Byte), Integer), CType(CType(0, Byte), Integer), CType(CType(128, Byte), Integer))
Me.GdViewer.AnnotationResizeRotateHandlesScale = 1.0!
Me.GdViewer.AnnotationSelectionLineColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(0, Byte), Integer), CType(CType(0, Byte), Integer))
@ -71,6 +72,8 @@ Partial Class DocumentViewer
Me.GdViewer.BackColor = System.Drawing.SystemColors.AppWorkspace
Me.GdViewer.BackgroundImage = Nothing
Me.GdViewer.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None
Me.GdViewer.ClipAnnotsToPageBounds = True
Me.GdViewer.ClipRegionsToPageBounds = True
Me.GdViewer.ContinuousViewMode = True
Me.GdViewer.DisplayQuality = GdPicture14.DisplayQuality.DisplayQualityAutomatic
Me.GdViewer.DisplayQualityAuto = True
@ -111,6 +114,7 @@ Partial Class DocumentViewer
Me.GdViewer.PdfShowDialogForPassword = True
Me.GdViewer.PdfShowOpenFileDialogForDecryption = True
Me.GdViewer.PdfVerifyDigitalCertificates = False
Me.GdViewer.PreserveViewRotation = True
Me.GdViewer.RectBorderColor = System.Drawing.Color.Black
Me.GdViewer.RectBorderSize = 1
Me.GdViewer.RectIsEditable = True
@ -329,6 +333,12 @@ Partial Class DocumentViewer
Me.barDockControlRight.Manager = Me.BarManager1
Me.barDockControlRight.Size = New System.Drawing.Size(0, 557)
'
'BarStaticItem1
'
Me.BarStaticItem1.Caption = "Seiten"
Me.BarStaticItem1.Id = 17
Me.BarStaticItem1.Name = "BarStaticItem1"
'
'RepositoryItemTextEdit1
'
Me.RepositoryItemTextEdit1.AutoHeight = False
@ -345,12 +355,6 @@ Partial Class DocumentViewer
Me.SpreadsheetControl1.Text = "SpreadsheetControl1"
Me.SpreadsheetControl1.Visible = False
'
'BarStaticItem1
'
Me.BarStaticItem1.Caption = "Seiten"
Me.BarStaticItem1.Id = 17
Me.BarStaticItem1.Name = "BarStaticItem1"
'
'DocumentViewer
'
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)

View File

@ -142,6 +142,26 @@
MSwwLjksMiwyLDJoNHY0aDE2di00aDRjMS4xLDAsMi0wLjksMi0yVjEyQzMwLDEwLjksMjkuMSwxMCwy
OCwxMHogTTIyLDI0djJ2MkgxMHYtMnYtMnYtNGgxMlYyNHoiIGlkPSJQcmludCIgY2xhc3M9IkJsYWNr
IiAvPg0KICA8L2c+DQo8L3N2Zz4L
</value>
</data>
<data name="buttonFitWidth.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v19.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
AAEAAAD/////AQAAAAAAAAAMAgAAAFlEZXZFeHByZXNzLkRhdGEudjE5LjIsIFZlcnNpb249MTkuMi4z
LjAsIEN1bHR1cmU9bmV1dHJhbCwgUHVibGljS2V5VG9rZW49Yjg4ZDE3NTRkNzAwZTQ5YQUBAAAAHURl
dkV4cHJlc3MuVXRpbHMuU3ZnLlN2Z0ltYWdlAQAAAAREYXRhBwICAAAACQMAAAAPAwAAAO4CAAAC77u/
PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0nVVRGLTgnPz4NCjxzdmcgeD0iMHB4IiB5PSIwcHgi
IHZpZXdCb3g9IjAgMCAzMiAzMiIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcv
MjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBlbmFibGUt
YmFja2dyb3VuZD0ibmV3IDAgMCAzMiAzMiIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgaWQ9IkxheWVyXzEi
Pg0KICA8ZyBpZD0iTGF5ZXJfMV8yXyI+DQogICAgPHBvbHlnb24gcG9pbnRzPSI0LDIgNCw0IDYsNCA2
LDIyIDQsMjIgNCwyNCA4LDI0IDgsMiAgIiBmaWxsPSIjMzc3QUI1IiAvPg0KICAgIDxwb2x5Z29uIHBv
aW50cz0iMTAsMzAgMTIsMzAgMTIsMjggMjYsMjggMjYsMzAgMjgsMzAgMjgsMjYgMTAsMjYgICIgZmls
bD0iIzM3N0FCNSIgLz4NCiAgICA8ZyBpZD0iTGF5ZXJfMV8xXyI+DQogICAgICA8cG9seWdvbiBwb2lu
dHM9IjEwLDIgMTAsMjQgMjgsMjQgMjgsOCAyMiwyICAgIiBvcGFjaXR5PSIwLjYiIC8+DQogICAgICA8
cG9seWdvbiBwb2ludHM9IjEyLDQgMTIsMjIgMjYsMjIgMjYsMTAgMjAsMTAgMjAsNCAgICIgZmlsbD0i
I0ZGRkZGRiIgLz4NCiAgICAgIDxwb2x5Z29uIHBvaW50cz0iMjIsNCAyMiw4IDI2LDggICAiIGZpbGw9
IiNGRkZGRkYiIC8+DQogICAgPC9nPg0KICAgIDxnIGlkPSJMYXllcl8yXzFfIiAvPg0KICA8L2c+DQog
IDxnIGlkPSJMYXllcl8yIiAvPg0KPC9zdmc+Cw==
</value>
</data>
<data name="buttonFitPage.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v19.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
@ -163,26 +183,6 @@
IjE2IiB3aWR0aD0iMTYiIGhlaWdodD0iMiIgcng9IjAiIHJ5PSIwIiBvcGFjaXR5PSIwLjMiIC8+DQog
IDxyZWN0IHg9IjgiIHk9IjIwIiB3aWR0aD0iMTYiIGhlaWdodD0iMiIgcng9IjAiIHJ5PSIwIiBvcGFj
aXR5PSIwLjMiIC8+DQo8L3N2Zz4L
</value>
</data>
<data name="buttonFitWidth.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v19.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
AAEAAAD/////AQAAAAAAAAAMAgAAAFlEZXZFeHByZXNzLkRhdGEudjE5LjIsIFZlcnNpb249MTkuMi4z
LjAsIEN1bHR1cmU9bmV1dHJhbCwgUHVibGljS2V5VG9rZW49Yjg4ZDE3NTRkNzAwZTQ5YQUBAAAAHURl
dkV4cHJlc3MuVXRpbHMuU3ZnLlN2Z0ltYWdlAQAAAAREYXRhBwICAAAACQMAAAAPAwAAAO4CAAAC77u/
PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0nVVRGLTgnPz4NCjxzdmcgeD0iMHB4IiB5PSIwcHgi
IHZpZXdCb3g9IjAgMCAzMiAzMiIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcv
MjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBlbmFibGUt
YmFja2dyb3VuZD0ibmV3IDAgMCAzMiAzMiIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgaWQ9IkxheWVyXzEi
Pg0KICA8ZyBpZD0iTGF5ZXJfMV8yXyI+DQogICAgPHBvbHlnb24gcG9pbnRzPSI0LDIgNCw0IDYsNCA2
LDIyIDQsMjIgNCwyNCA4LDI0IDgsMiAgIiBmaWxsPSIjMzc3QUI1IiAvPg0KICAgIDxwb2x5Z29uIHBv
aW50cz0iMTAsMzAgMTIsMzAgMTIsMjggMjYsMjggMjYsMzAgMjgsMzAgMjgsMjYgMTAsMjYgICIgZmls
bD0iIzM3N0FCNSIgLz4NCiAgICA8ZyBpZD0iTGF5ZXJfMV8xXyI+DQogICAgICA8cG9seWdvbiBwb2lu
dHM9IjEwLDIgMTAsMjQgMjgsMjQgMjgsOCAyMiwyICAgIiBvcGFjaXR5PSIwLjYiIC8+DQogICAgICA8
cG9seWdvbiBwb2ludHM9IjEyLDQgMTIsMjIgMjYsMjIgMjYsMTAgMjAsMTAgMjAsNCAgICIgZmlsbD0i
I0ZGRkZGRiIgLz4NCiAgICAgIDxwb2x5Z29uIHBvaW50cz0iMjIsNCAyMiw4IDI2LDggICAiIGZpbGw9
IiNGRkZGRkYiIC8+DQogICAgPC9nPg0KICAgIDxnIGlkPSJMYXllcl8yXzFfIiAvPg0KICA8L2c+DQog
IDxnIGlkPSJMYXllcl8yIiAvPg0KPC9zdmc+Cw==
</value>
</data>
<data name="buttonZoomIn.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v19.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
@ -222,25 +222,6 @@
NC42LTAuOCw2LjUtMi4xbDcuOSw3LjljMC4zLDAuMywwLjksMC4zLDEuMiwwbDEuMi0xLjJDMzAuMSwy
OC4yLDMwLjEsMjcuNiwyOS43LDI3LjN6IE00LDEzYzAtNSw0LTksOS05YzUsMCw5LDQsOSw5ICAgcy00
LDktOSw5QzgsMjIsNCwxOCw0LDEzeiIgY2xhc3M9IkJsYWNrIiAvPg0KICA8L2c+DQo8L3N2Zz4L
</value>
</data>
<data name="buttonRotateRight.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v19.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
AAEAAAD/////AQAAAAAAAAAMAgAAAFlEZXZFeHByZXNzLkRhdGEudjE5LjIsIFZlcnNpb249MTkuMi4z
LjAsIEN1bHR1cmU9bmV1dHJhbCwgUHVibGljS2V5VG9rZW49Yjg4ZDE3NTRkNzAwZTQ5YQUBAAAAHURl
dkV4cHJlc3MuVXRpbHMuU3ZnLlN2Z0ltYWdlAQAAAAREYXRhBwICAAAACQMAAAAPAwAAALACAAAC77u/
PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0nVVRGLTgnPz4NCjxzdmcgeD0iMHB4IiB5PSIwcHgi
IHZpZXdCb3g9IjAgMCAzMiAzMiIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcv
MjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4bWw6c3Bh
Y2U9InByZXNlcnZlIiBpZD0iTGF5ZXJfMSIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAg
MzIgMzIiPg0KICA8c3R5bGUgdHlwZT0idGV4dC9jc3MiPgoJLlllbGxvd3tmaWxsOiNGRkIxMTU7fQoJ
LlJlZHtmaWxsOiNEMTFDMUM7fQoJLkJsdWV7ZmlsbDojMTE3N0Q3O30KCS5HcmVlbntmaWxsOiMwMzlD
MjM7fQoJLkJsYWNre2ZpbGw6IzcyNzI3Mjt9CgkuV2hpdGV7ZmlsbDojRkZGRkZGO30KCS5zdDB7b3Bh
Y2l0eTowLjc1O30KPC9zdHlsZT4NCiAgPGcgaWQ9IlJvdGF0ZUNsb2Nrd2lzZSI+DQogICAgPHBhdGgg
ZD0iTTE4LjYsMjIuNkMxNy4zLDIzLjUsMTUuNywyNCwxNCwyNGMtNC40LDAtOC0zLjYtOC04czMuNi04
LDgtOHM4LDMuNiw4LDhoLTVsNyw3bDctN2gtNWMwLTYuNi01LjQtMTItMTItMTIgICBTMiw5LjQsMiwx
NmMwLDYuNiw1LjQsMTIsMTIsMTJjMi44LDAsNS40LTEsNy40LTIuNkwxOC42LDIyLjZ6IiBjbGFzcz0i
R3JlZW4iIC8+DQogIDwvZz4NCjwvc3ZnPgs=
</value>
</data>
<data name="buttonRotateLeft.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v19.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
@ -260,6 +241,25 @@
LThzOCwzLjYsOCw4cy0zLjYsOC04LDhjLTEuNywwLTMuMy0wLjUtNC42LTEuNCAgIGwtMi45LDIuOWMy
LDEuNiw0LjYsMi42LDcuNCwyLjZjNi42LDAsMTItNS40LDEyLTEyQzMwLDkuNCwyNC42LDQsMTgsNHoi
IGNsYXNzPSJHcmVlbiIgLz4NCiAgPC9nPg0KPC9zdmc+Cw==
</value>
</data>
<data name="buttonRotateRight.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v19.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
AAEAAAD/////AQAAAAAAAAAMAgAAAFlEZXZFeHByZXNzLkRhdGEudjE5LjIsIFZlcnNpb249MTkuMi4z
LjAsIEN1bHR1cmU9bmV1dHJhbCwgUHVibGljS2V5VG9rZW49Yjg4ZDE3NTRkNzAwZTQ5YQUBAAAAHURl
dkV4cHJlc3MuVXRpbHMuU3ZnLlN2Z0ltYWdlAQAAAAREYXRhBwICAAAACQMAAAAPAwAAALACAAAC77u/
PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0nVVRGLTgnPz4NCjxzdmcgeD0iMHB4IiB5PSIwcHgi
IHZpZXdCb3g9IjAgMCAzMiAzMiIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcv
MjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4bWw6c3Bh
Y2U9InByZXNlcnZlIiBpZD0iTGF5ZXJfMSIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAg
MzIgMzIiPg0KICA8c3R5bGUgdHlwZT0idGV4dC9jc3MiPgoJLlllbGxvd3tmaWxsOiNGRkIxMTU7fQoJ
LlJlZHtmaWxsOiNEMTFDMUM7fQoJLkJsdWV7ZmlsbDojMTE3N0Q3O30KCS5HcmVlbntmaWxsOiMwMzlD
MjM7fQoJLkJsYWNre2ZpbGw6IzcyNzI3Mjt9CgkuV2hpdGV7ZmlsbDojRkZGRkZGO30KCS5zdDB7b3Bh
Y2l0eTowLjc1O30KPC9zdHlsZT4NCiAgPGcgaWQ9IlJvdGF0ZUNsb2Nrd2lzZSI+DQogICAgPHBhdGgg
ZD0iTTE4LjYsMjIuNkMxNy4zLDIzLjUsMTUuNywyNCwxNCwyNGMtNC40LDAtOC0zLjYtOC04czMuNi04
LDgtOHM4LDMuNiw4LDhoLTVsNyw3bDctN2gtNWMwLTYuNi01LjQtMTItMTItMTIgICBTMiw5LjQsMiwx
NmMwLDYuNiw1LjQsMTIsMTIsMTJjMi44LDAsNS40LTEsNy40LTIuNkwxOC42LDIyLjZ6IiBjbGFzcz0i
R3JlZW4iIC8+DQogIDwvZz4NCjwvc3ZnPgs=
</value>
</data>
<data name="buttonFlipX.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v19.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
@ -296,28 +296,23 @@
L3N2Zz4L
</value>
</data>
<data name="buttonSettings.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v19.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
<data name="buttonFirstPage.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v19.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
AAEAAAD/////AQAAAAAAAAAMAgAAAFlEZXZFeHByZXNzLkRhdGEudjE5LjIsIFZlcnNpb249MTkuMi4z
LjAsIEN1bHR1cmU9bmV1dHJhbCwgUHVibGljS2V5VG9rZW49Yjg4ZDE3NTRkNzAwZTQ5YQUBAAAAHURl
dkV4cHJlc3MuVXRpbHMuU3ZnLlN2Z0ltYWdlAQAAAAREYXRhBwICAAAACQMAAAAPAwAAAO4DAAAC77u/
dkV4cHJlc3MuVXRpbHMuU3ZnLlN2Z0ltYWdlAQAAAAREYXRhBwICAAAACQMAAAAPAwAAAKACAAAC77u/
PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0nVVRGLTgnPz4NCjxzdmcgeD0iMHB4IiB5PSIwcHgi
IHZpZXdCb3g9IjAgMCAzMiAzMiIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcv
MjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4bWw6c3Bh
Y2U9InByZXNlcnZlIiBpZD0iTGF5ZXJfMSIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAg
MzIgMzIiPg0KICA8c3R5bGUgdHlwZT0idGV4dC9jc3MiPgoJLkJsYWNre2ZpbGw6IzcyNzI3Mjt9Cgku
WWVsbG93e2ZpbGw6I0ZGQjExNTt9CgkuQmx1ZXtmaWxsOiMxMTc3RDc7fQoJLkdyZWVue2ZpbGw6IzAz
OUMyMzt9CgkuUmVke2ZpbGw6I0QxMUMxQzt9CgkuV2hpdGV7ZmlsbDojRkZGRkZGO30KCS5zdDB7b3Bh
Y2l0eTowLjc1O30KCS5zdDF7b3BhY2l0eTowLjU7fQoJLnN0MntvcGFjaXR5OjAuMjU7fQo8L3N0eWxl
Pg0KICA8ZyBpZD0iUHJvcGVydGllcyI+DQogICAgPHBhdGggZD0iTTMwLDE4di00bC00LjQtMC43Yy0w
LjItMC44LTAuNS0xLjUtMC45LTIuMWwyLjYtMy42bC0yLjgtMi44bC0zLjYsMi42Yy0wLjctMC40LTEu
NC0wLjctMi4xLTAuOUwxOCwyaC00ICAgbC0wLjcsNC40Yy0wLjgsMC4yLTEuNSwwLjUtMi4xLDAuOUw3
LjUsNC43TDQuNyw3LjVsMi42LDMuNmMtMC40LDAuNy0wLjcsMS40LTAuOSwyLjFMMiwxNHY0bDQuNCww
LjdjMC4yLDAuOCwwLjUsMS41LDAuOSwyLjEgICBsLTIuNiwzLjZsMi44LDIuOGwzLjYtMi42YzAuNyww
LjQsMS40LDAuNywyLjEsMC45TDE0LDMwaDRsMC43LTQuNGMwLjgtMC4yLDEuNS0wLjUsMi4xLTAuOWwz
LjYsMi42bDIuOC0yLjhsLTIuNi0zLjYgICBjMC40LTAuNywwLjctMS40LDAuOS0yLjFMMzAsMTh6IE0x
NiwyMGMtMi4yLDAtNC0xLjgtNC00YzAtMi4yLDEuOC00LDQtNHM0LDEuOCw0LDRDMjAsMTguMiwxOC4y
LDIwLDE2LDIweiIgY2xhc3M9IkJsdWUiIC8+DQogIDwvZz4NCjwvc3ZnPgs=
Y2U9InByZXNlcnZlIiBzdHlsZT0iZW5hYmxlLWJhY2tncm91bmQ6bmV3IDAgMCAzMiAzMiI+DQogIDxz
dHlsZSB0eXBlPSJ0ZXh0L2NzcyI+CgkuQmx1ZXtmaWxsOiMxMTc3RDc7fQo8L3N0eWxlPg0KICA8ZyBp
ZD0iTGF5ZXJfMSI+DQogICAgPHBhdGggZD0iTTguMywxNS42Yy0wLjUtMC4zLTAuNS0wLjgsMC0xLjFs
MTEuOC03LjNWNC42YzAtMC42LTAuNC0wLjgtMC45LTAuNUwyLjQsMTQuNWMtMC41LDAuMy0wLjUsMC44
LDAsMS4xICAgbDE2LjgsMTAuM2MwLjUsMC4zLDAuOSwwLjEsMC45LTAuNXYtMi42TDguMywxNS42eiIg
Y2xhc3M9IkJsdWUiIC8+DQogICAgPHBhdGggZD0iTTEyLjMsMTQuNWMtMC41LDAuMy0wLjUsMC44LDAs
MS4xbDE2LjgsMTAuM2MwLjUsMC4zLDAuOSwwLjEsMC45LTAuNVY0LjdjMC0wLjYtMC40LTAuOC0wLjkt
MC41TDEyLjMsMTQuNXoiIGNsYXNzPSJCbHVlIiAvPg0KICA8L2c+DQogIDxnIGlkPSJMYXllcl8yIiAv
Pg0KPC9zdmc+Cw==
</value>
</data>
<data name="buttonPrevPage.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v19.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
@ -348,25 +343,6 @@
ZT4NCiAgPHBhdGggZD0iTTguOSw0LjFDOC40LDMuOCw4LDQuMSw4LDQuNnYyMC43YzAsMC42LDAuNCww
LjgsMC45LDAuNWwxNi44LTEwLjNjMC41LTAuMywwLjUtMC44LDAtMS4xTDguOSw0LjF6IiBjbGFzcz0i
Qmx1ZSIgLz4NCjwvc3ZnPgs=
</value>
</data>
<data name="buttonFirstPage.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v19.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
AAEAAAD/////AQAAAAAAAAAMAgAAAFlEZXZFeHByZXNzLkRhdGEudjE5LjIsIFZlcnNpb249MTkuMi4z
LjAsIEN1bHR1cmU9bmV1dHJhbCwgUHVibGljS2V5VG9rZW49Yjg4ZDE3NTRkNzAwZTQ5YQUBAAAAHURl
dkV4cHJlc3MuVXRpbHMuU3ZnLlN2Z0ltYWdlAQAAAAREYXRhBwICAAAACQMAAAAPAwAAAKACAAAC77u/
PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0nVVRGLTgnPz4NCjxzdmcgeD0iMHB4IiB5PSIwcHgi
IHZpZXdCb3g9IjAgMCAzMiAzMiIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcv
MjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4bWw6c3Bh
Y2U9InByZXNlcnZlIiBzdHlsZT0iZW5hYmxlLWJhY2tncm91bmQ6bmV3IDAgMCAzMiAzMiI+DQogIDxz
dHlsZSB0eXBlPSJ0ZXh0L2NzcyI+CgkuQmx1ZXtmaWxsOiMxMTc3RDc7fQo8L3N0eWxlPg0KICA8ZyBp
ZD0iTGF5ZXJfMSI+DQogICAgPHBhdGggZD0iTTguMywxNS42Yy0wLjUtMC4zLTAuNS0wLjgsMC0xLjFs
MTEuOC03LjNWNC42YzAtMC42LTAuNC0wLjgtMC45LTAuNUwyLjQsMTQuNWMtMC41LDAuMy0wLjUsMC44
LDAsMS4xICAgbDE2LjgsMTAuM2MwLjUsMC4zLDAuOSwwLjEsMC45LTAuNXYtMi42TDguMywxNS42eiIg
Y2xhc3M9IkJsdWUiIC8+DQogICAgPHBhdGggZD0iTTEyLjMsMTQuNWMtMC41LDAuMy0wLjUsMC44LDAs
MS4xbDE2LjgsMTAuM2MwLjUsMC4zLDAuOSwwLjEsMC45LTAuNVY0LjdjMC0wLjYtMC40LTAuOC0wLjkt
MC41TDEyLjMsMTQuNXoiIGNsYXNzPSJCbHVlIiAvPg0KICA8L2c+DQogIDxnIGlkPSJMYXllcl8yIiAv
Pg0KPC9zdmc+Cw==
</value>
</data>
<data name="buttonLastPage.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v19.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
@ -386,6 +362,30 @@
MS4xTDIuOSw0LjFDMi40LDMuOCwyLDQsMiw0LjZ2MjAuNmMwLDAuNiwwLjQsMC44LDAuOSwwLjVMMTku
NywxNS41eiIgY2xhc3M9IkJsdWUiIC8+DQogIDwvZz4NCiAgPGcgaWQ9IkxheWVyXzIiIC8+DQo8L3N2
Zz4L
</value>
</data>
<data name="buttonSettings.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v19.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
AAEAAAD/////AQAAAAAAAAAMAgAAAFlEZXZFeHByZXNzLkRhdGEudjE5LjIsIFZlcnNpb249MTkuMi4z
LjAsIEN1bHR1cmU9bmV1dHJhbCwgUHVibGljS2V5VG9rZW49Yjg4ZDE3NTRkNzAwZTQ5YQUBAAAAHURl
dkV4cHJlc3MuVXRpbHMuU3ZnLlN2Z0ltYWdlAQAAAAREYXRhBwICAAAACQMAAAAPAwAAAO4DAAAC77u/
PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0nVVRGLTgnPz4NCjxzdmcgeD0iMHB4IiB5PSIwcHgi
IHZpZXdCb3g9IjAgMCAzMiAzMiIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcv
MjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4bWw6c3Bh
Y2U9InByZXNlcnZlIiBpZD0iTGF5ZXJfMSIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAg
MzIgMzIiPg0KICA8c3R5bGUgdHlwZT0idGV4dC9jc3MiPgoJLkJsYWNre2ZpbGw6IzcyNzI3Mjt9Cgku
WWVsbG93e2ZpbGw6I0ZGQjExNTt9CgkuQmx1ZXtmaWxsOiMxMTc3RDc7fQoJLkdyZWVue2ZpbGw6IzAz
OUMyMzt9CgkuUmVke2ZpbGw6I0QxMUMxQzt9CgkuV2hpdGV7ZmlsbDojRkZGRkZGO30KCS5zdDB7b3Bh
Y2l0eTowLjc1O30KCS5zdDF7b3BhY2l0eTowLjU7fQoJLnN0MntvcGFjaXR5OjAuMjU7fQo8L3N0eWxl
Pg0KICA8ZyBpZD0iUHJvcGVydGllcyI+DQogICAgPHBhdGggZD0iTTMwLDE4di00bC00LjQtMC43Yy0w
LjItMC44LTAuNS0xLjUtMC45LTIuMWwyLjYtMy42bC0yLjgtMi44bC0zLjYsMi42Yy0wLjctMC40LTEu
NC0wLjctMi4xLTAuOUwxOCwyaC00ICAgbC0wLjcsNC40Yy0wLjgsMC4yLTEuNSwwLjUtMi4xLDAuOUw3
LjUsNC43TDQuNyw3LjVsMi42LDMuNmMtMC40LDAuNy0wLjcsMS40LTAuOSwyLjFMMiwxNHY0bDQuNCww
LjdjMC4yLDAuOCwwLjUsMS41LDAuOSwyLjEgICBsLTIuNiwzLjZsMi44LDIuOGwzLjYtMi42YzAuNyww
LjQsMS40LDAuNywyLjEsMC45TDE0LDMwaDRsMC43LTQuNGMwLjgtMC4yLDEuNS0wLjUsMi4xLTAuOWwz
LjYsMi42bDIuOC0yLjhsLTIuNi0zLjYgICBjMC40LTAuNywwLjctMS40LDAuOS0yLjFMMzAsMTh6IE0x
NiwyMGMtMi4yLDAtNC0xLjgtNC00YzAtMi4yLDEuOC00LDQtNHM0LDEuOCw0LDRDMjAsMTguMiwxOC4y
LDIwLDE2LDIweiIgY2xhc3M9IkJsdWUiIC8+DQogIDwvZz4NCjwvc3ZnPgs=
</value>
</data>
<metadata name="PrintDocument1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">

View File

@ -31,6 +31,7 @@ Public Class DocumentViewer
Private _hide_file_info_from_user As Boolean = False
Private _FilePath As String
' List of all created temp files when converting msg files
Private _TempFiles As New List(Of String)
@ -40,6 +41,8 @@ Public Class DocumentViewer
UpdateMainUi()
End Sub
Public Property FileLoaded As Boolean = False
''' <summary>
''' Initialize the Viewer
''' </summary>
@ -66,6 +69,8 @@ Public Class DocumentViewer
''' </summary>
''' <param name="FilePath"></param>
Public Sub LoadFile(FilePath As String)
FileLoaded = False
If _licenseKey = String.Empty Then
_logger.Warn("License key was not provided. File {0} not loaded.", FilePath)
Exit Sub
@ -73,12 +78,19 @@ Public Class DocumentViewer
_logger.Info("Loading File {0}", FilePath)
DoLoadFile(FilePath)
Dim oFileLoaded = DoLoadFile(FilePath)
_FilePath = FilePath
If oFileLoaded = True Then
FileLoaded = True
End If
UpdateMainUi()
End Sub
Public Sub LoadFile(FileName As String, Stream As Stream)
FileLoaded = False
If _licenseKey = String.Empty Then
_logger.Warn("License key was not provided. File [{0}] not loaded.", FileName)
Exit Sub
@ -88,7 +100,11 @@ Public Class DocumentViewer
_logger.Info("Loading File [{0}]", FileName)
DoLoadFile(Stream, oExtension)
Dim ofileloaded = DoLoadFile(Stream, oExtension)
If oFileLoaded = True Then
FileLoaded = True
End If
UpdateMainUi()
End Sub
@ -114,22 +130,23 @@ Public Class DocumentViewer
Dim oExtension As String = oFileInfo.Extension.ToUpper
Select Case oExtension.ToUpper
Case ".MSG"
RichEditControl1.CreateNewDocument()
Case ".EML", ".DOC", ".DOCX", ".ODT", ".RTF", ".TXT"
RichEditControl1.CreateNewDocument()
Case ".XLSX", ".XLS", "CSV"
SpreadsheetControl1.CreateNewDocument()
Case Else
GdViewer.CloseDocument()
End Select
Catch ex As Exception
_logger.Warn($"Unexpected error in FreeFile: {ex.Message}")
End Try
End Sub
Private Sub DoLoadFile(FilePath As String)
Private Function DoLoadFile(FilePath As String) As Boolean
Try
Dim oFileInfo = New IO.FileInfo(FilePath)
Dim oExtension As String = oFileInfo.Extension.ToUpper
@ -183,12 +200,15 @@ Public Class DocumentViewer
End Select
UpdateMainUi()
Return True
Catch ex As Exception
_logger.Error(ex)
Return False
End Try
End Sub
End Function
Private Sub DoLoadFile(Stream As Stream, Extension As String)
Private Function DoLoadFile(Stream As Stream, Extension As String) As Boolean
Try
RichEditControl1.Visible = False
RichEditControl1.Dock = DockStyle.None
@ -240,10 +260,13 @@ Public Class DocumentViewer
End Select
UpdateMainUi()
Return True
Catch ex As Exception
_logger.Error(ex)
Return False
End Try
End Sub
End Function
Private Function GetSpreadsheetFormat(Extension) As Spreadsheet.DocumentFormat
Dim oFormat As Spreadsheet.DocumentFormat = Spreadsheet.DocumentFormat.Undefined
@ -257,7 +280,7 @@ Public Class DocumentViewer
Return oFormat
End Function
Private Function GetDocumentFormat(Extension)
Private Function GetDocumentFormat(Extension) As XtraRichEdit.DocumentFormat
Dim oFormat As XtraRichEdit.DocumentFormat = XtraRichEdit.DocumentFormat.Undefined
Select Case Extension.ToUpper
@ -444,4 +467,5 @@ Public Class DocumentViewer
Private Sub btnSettings_Click(sender As Object, e As XtraBars.ItemClickEventArgs) Handles buttonSettings.ItemClick
End Sub
End Class

View File

@ -121,12 +121,6 @@
<Compile Include="DocumentViewer.vb">
<SubType>UserControl</SubType>
</Compile>
<Compile Include="frmViewerPrint.Designer.vb">
<DependentUpon>frmViewerPrint.vb</DependentUpon>
</Compile>
<Compile Include="frmViewerPrint.vb">
<SubType>Form</SubType>
</Compile>
<Compile Include="frmViewerSettings.Designer.vb">
<DependentUpon>frmViewerSettings.vb</DependentUpon>
</Compile>
@ -153,9 +147,6 @@
<EmbeddedResource Include="DocumentViewer.resx">
<DependentUpon>DocumentViewer.vb</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="frmViewerPrint.resx">
<DependentUpon>frmViewerPrint.vb</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="frmViewerSettings.resx">
<DependentUpon>frmViewerSettings.vb</DependentUpon>
</EmbeddedResource>

View File

@ -1,348 +0,0 @@
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
Partial Class frmViewerPrint
Inherits System.Windows.Forms.Form
'Das Formular überschreibt den Löschvorgang, um die Komponentenliste zu bereinigen.
<System.Diagnostics.DebuggerNonUserCode()> _
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
Try
If disposing AndAlso components IsNot Nothing Then
components.Dispose()
End If
Finally
MyBase.Dispose(disposing)
End Try
End Sub
'Wird vom Windows Form-Designer benötigt.
Private components As System.ComponentModel.IContainer
'Hinweis: Die folgende Prozedur ist für den Windows Form-Designer erforderlich.
'Das Bearbeiten ist mit dem Windows Form-Designer möglich.
'Das Bearbeiten mit dem Code-Editor ist nicht möglich.
<System.Diagnostics.DebuggerStepThrough()> _
Private Sub InitializeComponent()
Me.numCopies = New System.Windows.Forms.NumericUpDown()
Me.cmbPrintAlignment = New System.Windows.Forms.ComboBox()
Me.chkCollate = New System.Windows.Forms.CheckBox()
Me.lblPrintAlignment = New System.Windows.Forms.Label()
Me.grpPageRange = New System.Windows.Forms.GroupBox()
Me.txtPageRangeEnd = New System.Windows.Forms.TextBox()
Me.lblPageRangeTo = New System.Windows.Forms.Label()
Me.txtPageRangeStart = New System.Windows.Forms.TextBox()
Me.rbPageRangePages = New System.Windows.Forms.RadioButton()
Me.rbPageRangeCurrent = New System.Windows.Forms.RadioButton()
Me.rbPageRangeSelection = New System.Windows.Forms.RadioButton()
Me.rbPageRangeAll = New System.Windows.Forms.RadioButton()
Me.cmbPrintSize = New System.Windows.Forms.ComboBox()
Me.btnPrinterProperties = New System.Windows.Forms.Button()
Me.lblPrintSize = New System.Windows.Forms.Label()
Me.cmbPrinterList = New System.Windows.Forms.ComboBox()
Me.lblCopies = New System.Windows.Forms.Label()
Me.lblPrinter = New System.Windows.Forms.Label()
Me.btnCancel = New System.Windows.Forms.Button()
Me.btnPrint = New System.Windows.Forms.Button()
Me.grpOrientation = New System.Windows.Forms.GroupBox()
Me.rbOrientationLandscape = New System.Windows.Forms.RadioButton()
Me.rbOrientationPortrait = New System.Windows.Forms.RadioButton()
Me.rbOrientationAutomatic = New System.Windows.Forms.RadioButton()
CType(Me.numCopies, System.ComponentModel.ISupportInitialize).BeginInit()
Me.grpPageRange.SuspendLayout()
Me.grpOrientation.SuspendLayout()
Me.SuspendLayout()
'
'numCopies
'
Me.numCopies.Location = New System.Drawing.Point(140, 33)
Me.numCopies.Name = "numCopies"
Me.numCopies.Size = New System.Drawing.Size(61, 20)
Me.numCopies.TabIndex = 47
Me.numCopies.TextAlign = System.Windows.Forms.HorizontalAlignment.Right
Me.numCopies.Value = New Decimal(New Integer() {1, 0, 0, 0})
'
'cmbPrintAlignment
'
Me.cmbPrintAlignment.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList
Me.cmbPrintAlignment.FormattingEnabled = True
Me.cmbPrintAlignment.Location = New System.Drawing.Point(140, 87)
Me.cmbPrintAlignment.Name = "cmbPrintAlignment"
Me.cmbPrintAlignment.Size = New System.Drawing.Size(198, 21)
Me.cmbPrintAlignment.TabIndex = 38
'
'chkCollate
'
Me.chkCollate.AutoSize = True
Me.chkCollate.Location = New System.Drawing.Point(207, 37)
Me.chkCollate.Name = "chkCollate"
Me.chkCollate.Size = New System.Drawing.Size(58, 17)
Me.chkCollate.TabIndex = 36
Me.chkCollate.Text = "Collate"
Me.chkCollate.UseVisualStyleBackColor = True
'
'lblPrintAlignment
'
Me.lblPrintAlignment.AutoSize = True
Me.lblPrintAlignment.Location = New System.Drawing.Point(12, 90)
Me.lblPrintAlignment.Name = "lblPrintAlignment"
Me.lblPrintAlignment.Size = New System.Drawing.Size(53, 13)
Me.lblPrintAlignment.TabIndex = 45
Me.lblPrintAlignment.Text = "Alignment"
'
'grpPageRange
'
Me.grpPageRange.Controls.Add(Me.txtPageRangeEnd)
Me.grpPageRange.Controls.Add(Me.lblPageRangeTo)
Me.grpPageRange.Controls.Add(Me.txtPageRangeStart)
Me.grpPageRange.Controls.Add(Me.rbPageRangePages)
Me.grpPageRange.Controls.Add(Me.rbPageRangeCurrent)
Me.grpPageRange.Controls.Add(Me.rbPageRangeSelection)
Me.grpPageRange.Controls.Add(Me.rbPageRangeAll)
Me.grpPageRange.Location = New System.Drawing.Point(236, 114)
Me.grpPageRange.Name = "grpPageRange"
Me.grpPageRange.Size = New System.Drawing.Size(288, 100)
Me.grpPageRange.TabIndex = 42
Me.grpPageRange.TabStop = False
Me.grpPageRange.Text = "Page range"
'
'txtPageRangeEnd
'
Me.txtPageRangeEnd.Location = New System.Drawing.Point(169, 68)
Me.txtPageRangeEnd.Name = "txtPageRangeEnd"
Me.txtPageRangeEnd.Size = New System.Drawing.Size(42, 20)
Me.txtPageRangeEnd.TabIndex = 17
'
'lblPageRangeTo
'
Me.lblPageRangeTo.AutoSize = True
Me.lblPageRangeTo.Location = New System.Drawing.Point(146, 73)
Me.lblPageRangeTo.Name = "lblPageRangeTo"
Me.lblPageRangeTo.Size = New System.Drawing.Size(16, 13)
Me.lblPageRangeTo.TabIndex = 16
Me.lblPageRangeTo.Text = "to"
Me.lblPageRangeTo.TextAlign = System.Drawing.ContentAlignment.TopCenter
'
'txtPageRangeStart
'
Me.txtPageRangeStart.Location = New System.Drawing.Point(98, 68)
Me.txtPageRangeStart.Name = "txtPageRangeStart"
Me.txtPageRangeStart.Size = New System.Drawing.Size(42, 20)
Me.txtPageRangeStart.TabIndex = 16
'
'rbPageRangePages
'
Me.rbPageRangePages.AutoSize = True
Me.rbPageRangePages.Location = New System.Drawing.Point(13, 69)
Me.rbPageRangePages.Name = "rbPageRangePages"
Me.rbPageRangePages.Size = New System.Drawing.Size(78, 17)
Me.rbPageRangePages.TabIndex = 15
Me.rbPageRangePages.TabStop = True
Me.rbPageRangePages.Text = "Pages from"
Me.rbPageRangePages.UseVisualStyleBackColor = True
'
'rbPageRangeCurrent
'
Me.rbPageRangeCurrent.AutoSize = True
Me.rbPageRangeCurrent.Location = New System.Drawing.Point(149, 21)
Me.rbPageRangeCurrent.Name = "rbPageRangeCurrent"
Me.rbPageRangeCurrent.Size = New System.Drawing.Size(86, 17)
Me.rbPageRangeCurrent.TabIndex = 14
Me.rbPageRangeCurrent.TabStop = True
Me.rbPageRangeCurrent.Text = "Current page"
Me.rbPageRangeCurrent.UseVisualStyleBackColor = True
'
'rbPageRangeSelection
'
Me.rbPageRangeSelection.AutoSize = True
Me.rbPageRangeSelection.Enabled = False
Me.rbPageRangeSelection.Location = New System.Drawing.Point(13, 45)
Me.rbPageRangeSelection.Name = "rbPageRangeSelection"
Me.rbPageRangeSelection.Size = New System.Drawing.Size(100, 17)
Me.rbPageRangeSelection.TabIndex = 13
Me.rbPageRangeSelection.TabStop = True
Me.rbPageRangeSelection.Text = "Checked pages"
Me.rbPageRangeSelection.UseVisualStyleBackColor = True
'
'rbPageRangeAll
'
Me.rbPageRangeAll.AutoSize = True
Me.rbPageRangeAll.Checked = True
Me.rbPageRangeAll.Location = New System.Drawing.Point(13, 21)
Me.rbPageRangeAll.Name = "rbPageRangeAll"
Me.rbPageRangeAll.Size = New System.Drawing.Size(36, 17)
Me.rbPageRangeAll.TabIndex = 12
Me.rbPageRangeAll.TabStop = True
Me.rbPageRangeAll.Text = "All"
Me.rbPageRangeAll.UseVisualStyleBackColor = True
'
'cmbPrintSize
'
Me.cmbPrintSize.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList
Me.cmbPrintSize.FormattingEnabled = True
Me.cmbPrintSize.Location = New System.Drawing.Point(140, 60)
Me.cmbPrintSize.Name = "cmbPrintSize"
Me.cmbPrintSize.Size = New System.Drawing.Size(198, 21)
Me.cmbPrintSize.TabIndex = 37
'
'btnPrinterProperties
'
Me.btnPrinterProperties.Location = New System.Drawing.Point(417, 5)
Me.btnPrinterProperties.Name = "btnPrinterProperties"
Me.btnPrinterProperties.Size = New System.Drawing.Size(107, 23)
Me.btnPrinterProperties.TabIndex = 35
Me.btnPrinterProperties.Text = "Properties"
Me.btnPrinterProperties.UseVisualStyleBackColor = True
'
'lblPrintSize
'
Me.lblPrintSize.AutoSize = True
Me.lblPrintSize.Location = New System.Drawing.Point(12, 63)
Me.lblPrintSize.Name = "lblPrintSize"
Me.lblPrintSize.Size = New System.Drawing.Size(49, 13)
Me.lblPrintSize.TabIndex = 43
Me.lblPrintSize.Text = "Print size"
'
'cmbPrinterList
'
Me.cmbPrinterList.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList
Me.cmbPrinterList.FormattingEnabled = True
Me.cmbPrinterList.Location = New System.Drawing.Point(140, 6)
Me.cmbPrinterList.Name = "cmbPrinterList"
Me.cmbPrinterList.Size = New System.Drawing.Size(271, 21)
Me.cmbPrinterList.TabIndex = 34
'
'lblCopies
'
Me.lblCopies.AutoSize = True
Me.lblCopies.Location = New System.Drawing.Point(12, 35)
Me.lblCopies.Name = "lblCopies"
Me.lblCopies.Size = New System.Drawing.Size(39, 13)
Me.lblCopies.TabIndex = 41
Me.lblCopies.Text = "Copies"
'
'lblPrinter
'
Me.lblPrinter.AutoSize = True
Me.lblPrinter.Location = New System.Drawing.Point(12, 9)
Me.lblPrinter.Name = "lblPrinter"
Me.lblPrinter.Size = New System.Drawing.Size(37, 13)
Me.lblPrinter.TabIndex = 39
Me.lblPrinter.Text = "Printer"
'
'btnCancel
'
Me.btnCancel.Location = New System.Drawing.Point(449, 230)
Me.btnCancel.Name = "btnCancel"
Me.btnCancel.Size = New System.Drawing.Size(75, 23)
Me.btnCancel.TabIndex = 46
Me.btnCancel.Text = "Cancel"
Me.btnCancel.UseVisualStyleBackColor = True
'
'btnPrint
'
Me.btnPrint.Location = New System.Drawing.Point(365, 230)
Me.btnPrint.Name = "btnPrint"
Me.btnPrint.Size = New System.Drawing.Size(74, 23)
Me.btnPrint.TabIndex = 44
Me.btnPrint.Text = "Print"
Me.btnPrint.UseVisualStyleBackColor = True
'
'grpOrientation
'
Me.grpOrientation.Controls.Add(Me.rbOrientationLandscape)
Me.grpOrientation.Controls.Add(Me.rbOrientationPortrait)
Me.grpOrientation.Controls.Add(Me.rbOrientationAutomatic)
Me.grpOrientation.Location = New System.Drawing.Point(15, 114)
Me.grpOrientation.Name = "grpOrientation"
Me.grpOrientation.Size = New System.Drawing.Size(200, 100)
Me.grpOrientation.TabIndex = 40
Me.grpOrientation.TabStop = False
Me.grpOrientation.Text = "Orientation"
'
'rbOrientationLandscape
'
Me.rbOrientationLandscape.AutoSize = True
Me.rbOrientationLandscape.Location = New System.Drawing.Point(13, 68)
Me.rbOrientationLandscape.Name = "rbOrientationLandscape"
Me.rbOrientationLandscape.Size = New System.Drawing.Size(78, 17)
Me.rbOrientationLandscape.TabIndex = 10
Me.rbOrientationLandscape.Text = "Landscape"
Me.rbOrientationLandscape.UseVisualStyleBackColor = True
'
'rbOrientationPortrait
'
Me.rbOrientationPortrait.AutoSize = True
Me.rbOrientationPortrait.Location = New System.Drawing.Point(13, 45)
Me.rbOrientationPortrait.Name = "rbOrientationPortrait"
Me.rbOrientationPortrait.Size = New System.Drawing.Size(58, 17)
Me.rbOrientationPortrait.TabIndex = 9
Me.rbOrientationPortrait.Text = "Portrait"
Me.rbOrientationPortrait.UseVisualStyleBackColor = True
'
'rbOrientationAutomatic
'
Me.rbOrientationAutomatic.AutoSize = True
Me.rbOrientationAutomatic.Checked = True
Me.rbOrientationAutomatic.Location = New System.Drawing.Point(13, 22)
Me.rbOrientationAutomatic.Name = "rbOrientationAutomatic"
Me.rbOrientationAutomatic.Size = New System.Drawing.Size(72, 17)
Me.rbOrientationAutomatic.TabIndex = 8
Me.rbOrientationAutomatic.TabStop = True
Me.rbOrientationAutomatic.Text = "Automatic"
Me.rbOrientationAutomatic.UseVisualStyleBackColor = True
'
'frmViewerPrint
'
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
Me.ClientSize = New System.Drawing.Size(534, 265)
Me.Controls.Add(Me.numCopies)
Me.Controls.Add(Me.cmbPrintAlignment)
Me.Controls.Add(Me.chkCollate)
Me.Controls.Add(Me.lblPrintAlignment)
Me.Controls.Add(Me.grpPageRange)
Me.Controls.Add(Me.cmbPrintSize)
Me.Controls.Add(Me.btnPrinterProperties)
Me.Controls.Add(Me.lblPrintSize)
Me.Controls.Add(Me.cmbPrinterList)
Me.Controls.Add(Me.lblCopies)
Me.Controls.Add(Me.lblPrinter)
Me.Controls.Add(Me.btnCancel)
Me.Controls.Add(Me.btnPrint)
Me.Controls.Add(Me.grpOrientation)
Me.Name = "frmViewerPrint"
Me.Text = "frmViewerPrint"
CType(Me.numCopies, System.ComponentModel.ISupportInitialize).EndInit()
Me.grpPageRange.ResumeLayout(False)
Me.grpPageRange.PerformLayout()
Me.grpOrientation.ResumeLayout(False)
Me.grpOrientation.PerformLayout()
Me.ResumeLayout(False)
Me.PerformLayout()
End Sub
Friend WithEvents numCopies As NumericUpDown
Friend WithEvents cmbPrintAlignment As ComboBox
Friend WithEvents chkCollate As CheckBox
Friend WithEvents lblPrintAlignment As Label
Friend WithEvents grpPageRange As GroupBox
Friend WithEvents txtPageRangeEnd As TextBox
Friend WithEvents lblPageRangeTo As Label
Friend WithEvents txtPageRangeStart As TextBox
Friend WithEvents rbPageRangePages As RadioButton
Friend WithEvents rbPageRangeCurrent As RadioButton
Friend WithEvents rbPageRangeSelection As RadioButton
Friend WithEvents rbPageRangeAll As RadioButton
Friend WithEvents cmbPrintSize As ComboBox
Friend WithEvents btnPrinterProperties As Button
Friend WithEvents lblPrintSize As Label
Friend WithEvents cmbPrinterList As ComboBox
Friend WithEvents lblCopies As Label
Friend WithEvents lblPrinter As Label
Friend WithEvents btnCancel As Button
Friend WithEvents btnPrint As Button
Friend WithEvents grpOrientation As GroupBox
Friend WithEvents rbOrientationLandscape As RadioButton
Friend WithEvents rbOrientationPortrait As RadioButton
Friend WithEvents rbOrientationAutomatic As RadioButton
End Class

View File

@ -1,120 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@ -1,137 +0,0 @@
Option Explicit On
Option Infer On
Option Strict On
Imports System.Windows.Forms
Imports GdPicture14
Public Class frmViewerPrint
Enum PrintOrientation
AutoDetection
Portrait
Paysage
End Enum
Enum PagesToPrint
All
Selection
Current
Range
End Enum
Public Structure PrintSettings
Public Printer As String
Public Copies As Short
Public Collate As Boolean
Public PrintSize As PrintSizeOption
Public PrintAlignment As PrintAlignment
Public Orientation As PrintOrientation
Public PagesToPrint As PagesToPrint
Public PageRange As String
End Structure
Private m_printSettings As PrintSettings
Private ReadOnly m_owner As GdViewer
Public ReadOnly Property printConfiguration() As PrintSettings
Get
Return m_printSettings
End Get
End Property
Private ReadOnly m_isSelectionPartial As Boolean
Private ReadOnly m_isEmptySelection As Boolean
Public Sub New(ByVal owner As GdViewer)
InitializeComponent()
m_owner = owner
End Sub
Private Sub frmPrint_Load(ByVal sender As Object, ByVal e As EventArgs)
cmbPrinterList.Items.Clear()
For i As Integer = 1 To m_owner.PrintGetPrintersCount()
Dim printerName As String = m_owner.PrintGetPrinterName(i)
cmbPrinterList.Items.Add(printerName)
If printerName = m_owner.PrintGetActivePrinter() Then
cmbPrinterList.SelectedIndex = cmbPrinterList.Items.IndexOf(printerName)
End If
Next i
cmbPrintSize.Items.Add("Actual size") '0 = PrintSizeOptionActual
cmbPrintSize.Items.Add("Fit to page") '1 = PrintSizeOptionFit, default
cmbPrintSize.Items.Add("Shrink oversized pages") '2 = PrintSizeOptionShrinkOversized
cmbPrintSize.SelectedIndex = 2
cmbPrintAlignment.Items.Add("Middle left") '0 = PrintAlignmentMiddleLeft
cmbPrintAlignment.Items.Add("Middle right") '1 = PrintAlignmentMiddleRight
cmbPrintAlignment.Items.Add("Middle center") '2 = PrintAlignmentMiddleCenter
cmbPrintAlignment.Items.Add("Default") '3 = PrintAlignmentDefault
cmbPrintAlignment.Items.Add("Top left") '4 = PrintAlignmentTopLeft
cmbPrintAlignment.Items.Add("Top right") '5 = PrintAlignmentTopRight
cmbPrintAlignment.Items.Add("Top center") '6 = PrintAlignmentTopCenter
cmbPrintAlignment.Items.Add("Bottom left") '7 = PrintAlignmentBottomLeft
cmbPrintAlignment.Items.Add("Bottom right") '8 = PrintAlignmentBottomRight
cmbPrintAlignment.Items.Add("Bottom center") '9 = PrintAlignmentBottomCenter
cmbPrintAlignment.SelectedIndex = 2
If m_isEmptySelection Then
rbPageRangeSelection.Enabled = False
Else
If m_isSelectionPartial Then
rbPageRangeSelection.Checked = True
End If
End If
txtPageRangeStart.Enabled = False
txtPageRangeEnd.Enabled = False
txtPageRangeStart.Text = "1"
txtPageRangeEnd.Text = m_owner.PageCount.ToString()
btnPrint.DialogResult = DialogResult.OK
btnCancel.DialogResult = DialogResult.Cancel
End Sub
Private Sub btnPrinterProperties_Click(ByVal sender As Object, ByVal e As EventArgs) Handles btnPrinterProperties.Click
End Sub
Private Sub cmbPrinterList_SelectedIndexChanged(ByVal sender As Object, ByVal e As EventArgs) Handles cmbPrinterList.SelectedIndexChanged
End Sub
Private Sub btnCancel_Click(ByVal sender As Object, ByVal e As EventArgs) Handles btnCancel.Click
Me.Close()
End Sub
Private Sub rbPageRangeAll_CheckedChanged(ByVal sender As Object, ByVal e As EventArgs) Handles rbPageRangeAll.CheckedChanged
rbPageRangeGeneric_CheckedChanged()
End Sub
Private Sub rbPageRangeSelection_CheckedChanged(ByVal sender As Object, ByVal e As EventArgs) Handles rbPageRangeSelection.CheckedChanged
rbPageRangeGeneric_CheckedChanged()
End Sub
Private Sub rbPageRangeCurrent_CheckedChanged(ByVal sender As Object, ByVal e As EventArgs) Handles rbPageRangeCurrent.CheckedChanged
rbPageRangeGeneric_CheckedChanged()
End Sub
Private Sub rbPageRangePages_CheckedChanged(ByVal sender As Object, ByVal e As EventArgs) Handles rbPageRangePages.CheckedChanged
rbPageRangeGeneric_CheckedChanged()
End Sub
Private Sub rbPageRangeGeneric_CheckedChanged()
If rbPageRangePages.Checked Then
txtPageRangeStart.Enabled = True
txtPageRangeEnd.Enabled = True
Else
txtPageRangeStart.Enabled = False
txtPageRangeEnd.Enabled = False
End If
End Sub
Private Sub btnPrint_Click(ByVal sender As Object, ByVal e As EventArgs) Handles btnPrint.Click
End Sub
End Class