|
-
Mar 20th, 2006, 11:46 AM
#1
Thread Starter
Junior Member
open excel worksheet in vb.net
I can open the workbook but cant open the worksheet i need.
Here is the code i have so far.....
Private Sub btnstaff_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnstaff.Click
Dim ApExcel As Object 'To open Excel
ApExcel = CreateObject("Excel.application") 'Creates an object
ApExcel.Visible = True ' So you can see Excel
ApExcel.Workbooks.open("C:\documents and settings\mike\desktop\dss.xls")
I want to be able to define the worksheet (in this case, sheet 3)
Please help
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
|