Imports System.Data
Imports System.Data.OleDb
Imports System.Globalization
Imports CrystalDecisions.CrystalReports.Engine
Public Class FmReport


    Private Sub FmReport_Load(sender As Object, e As EventArgs) Handles MyBase.Load
        ConnectDatabase()
        Label16.Text = Today
    End Sub

    Private Sub Button5_Click(sender As Object, e As EventArgs) Handles Button5.Click
        Main.Show()
        Me.Hide()
    End Sub

    Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
        Dim rpt As New ReportDocument
        Dim dir As String = My.Application.Info.DirectoryPath

        rpt.Load("D:\ProjactBc\Projaet MS\Projaet MS\CrystalReport1.rpt")

        rpt1.CrystalReportViewer1.ReportSource = rpt
        rpt1.CrystalReportViewer1.Refresh()
        rpt1.Show()
    End Sub

    Private Sub Button4_Click(sender As Object, e As EventArgs) Handles Button4.Click
        Dim rpt As New ReportDocument
        Dim dir As String = My.Application.Info.DirectoryPath

        rpt.Load("D:\ProjactBc\Projaet MS\Projaet MS\CrystalReport2.rpt")

        rpt1.CrystalReportViewer1.ReportSource = rpt
        rpt1.CrystalReportViewer1.Refresh()
        rpt1.Show()
    End Sub
End Class