|
-
Sep 13th, 2005, 05:39 AM
#1
Thread Starter
New Member
vb6 to vb.net build errors
I have this program built in VB6 tried to convert to vb net but getting build erroes on my module. What do I need to change in this to get it to work?
Option Strict Off
Option Explicit On
Module Module1
Public Sub ssdprint()
Dim excel_app As Object
Dim worksheet1 As Object
excel_app = CreateObject("Excel.Application")
'UPGRADE_WARNING: Couldn't resolve default property of object excel_app.Workbooks. Click for more: 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="vbup1037"'
excel_app.Workbooks.Open(FileName:=VB6.GetPath & "\Book1.xls")
'UPGRADE_WARNING: Couldn't resolve default property of object excel_app.Run. Click for more: 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="vbup1037"'
excel_app.Run("SSDprint")
'UPGRADE_WARNING: Couldn't resolve default property of object excel_app.Run. Click for more: 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="vbup1037"'
excel_app.Run("CopyWorksheetsToWord")
'UPGRADE_WARNING: Couldn't resolve default property of object excel_app.Run. Click for more: 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="vbup1037"'
excel_app.Run("unhide")
'UPGRADE_WARNING: Couldn't resolve default property of object excel_app.ActiveWorkbook. Click for more: 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="vbup1037"'
excel_app.ActiveWorkbook.Close(True)
'UPGRADE_WARNING: Couldn't resolve default property of object excel_app.Quit. Click for more: 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="vbup1037"'
excel_app.Quit()
'UPGRADE_NOTE: Object worksheet1 may not be destroyed until it is garbage collected. Click for more: 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="vbup1029"'
worksheet1 = Nothing
'UPGRADE_NOTE: Object excel_app may not be destroyed until it is garbage collected. Click for more: 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="vbup1029"'
excel_app = Nothing
End Sub
End Module
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|