fix documentviewer in showdialog
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
Imports DigitalData.Modules.Logging
|
||||
|
||||
Public Class Form1
|
||||
Private oSubform As Form2
|
||||
|
||||
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
|
||||
Dim oResult = OpenFileDialog1.ShowDialog()
|
||||
|
||||
@@ -10,7 +12,8 @@ Public Class Form1
|
||||
End Sub
|
||||
Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
|
||||
Try
|
||||
DocumentViewer1.LoadFile(TextBox1.Text)
|
||||
oSubform.FilePath = TextBox1.Text
|
||||
oSubform.ShowDialog()
|
||||
Catch ex As Exception
|
||||
MsgBox(ex.Message)
|
||||
End Try
|
||||
@@ -19,6 +22,12 @@ Public Class Form1
|
||||
Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
|
||||
Dim oKey = "0467389434974657969312056"
|
||||
Dim oLogConfig As New LogConfig(LogConfig.PathType.CurrentDirectory)
|
||||
DocumentViewer1.Init(oLogConfig, oKey)
|
||||
oSubform = New Form2(oLogConfig, oKey)
|
||||
End Sub
|
||||
|
||||
Private Sub Form1_FormClosing(sender As Object, e As FormClosingEventArgs) Handles Me.FormClosing
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
End Class
|
||||
|
||||
Reference in New Issue
Block a user