|
-
Dec 27th, 2000, 09:29 AM
#1
Thread Starter
Member
How to enter values in createnew ole control.
I don’t want by ole automation
I placed an ole in my form1 and I selected the excel sheet from createnew option button.
By default my form contains 11 columns.In the same form under the excel sheet I placed a 2 textboxes.
My doubt is I want to enter the values in my form1 excel sheet through textbox.
But my code is creating new excel sheet.
Code.
Commandclick event
Dim xlApp As Object
Dim xlbook As Workbook
Dim xlsheet As Worksheet
Set xlApp = New Excel.Application
Set xlbook = xlApp.Workbooks.Add
Set xlsheet = xlbook.Worksheets.Add
xlsheet.Cells(1, 1) = text1.text
xlsheet.cells(2,1)=text2.text
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
|