Private Conn As New ADODB.Connection
Private mRS As New ADODB.Recordset
Private strYybdm As String
Dim varghzh As Variant, varnhzh As Variant
Private Sub Command6_Click()
Dim xlApp As Excel.Application
Set xlApp = New Excel.Application
Set xlApp = CreateObject("Excel.Application")
xlApp.Visible = False
Dim strSource, strDestination As String
If Check1 Then
strSource = App.Path & "\dynhmb.xls"
strDestination = App.Path & "\Temp.xls"
On Error GoTo Err
FileCopy strSource, strDestination
Set xlbook = xlApp.Workbooks.Open(strDestination)
Set xlsheet = xlbook.Worksheets(1)