Private Sub Button4_Click(sender As Object, e As EventArgs) Handles Button4.Click
Try
If objConn.State = ConnectionState.Closed Then
ConDB()
Else
End If
strSQL = "SELECT * FROM bb_report WHERE rpt_id=1;"
With objCmd
.Connection = objConn
.CommandText = strSQL
.CommandType = CommandType.Text
End With
Dim myData As MySqlDataReader
myData = objCmd.ExecuteReader
myData.Read()
Dim rfile As Byte() = myData("rpt_file")
File.WriteAllBytes("D:\rfileCR.rpt", rfile)
System.Diagnostics.Process.Start("D:\rfileCR.rpt")
Catch ex As Exception
MessageBox.Show(ex.Message.ToString)
End Try
End Sub