ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   OLE Objects (https://www.excelbanter.com/excel-discussion-misc-queries/179211-ole-objects.html)

[email protected]

OLE Objects
 
i'm copying a form on excel from an application built on java
platform.

what i'm tring to do is get the value of the OLEobjects copied from
the form into excel.

first i tried the code mentioned below but this will take me ages to
do as there are wround 300 optionbutton and from them i need data in
100 cells.

If ActiveSheet.HTMLOption1.Checked = "True" Then
Sheets(2).Range("A1").Value = "Yes"
If ActiveSheet.HTMLOption2.Checked = "True" Then
Sheets(2).Range("A1").Value = "No"
If ActiveSheet.HTMLOption3.Checked = "True" Then
Sheets(2).Range("A1").Value = "N/A"

then i tried

For i = 1 To ActiveSheet.OLEObjects.Count
Sheets(2).Range("A" & i).Value = ActiveSheet.OLEObjects(i).Object
Next i

it is also not helping much as the value lands up not in the order i
want.

-Thanks


All times are GMT +1. The time now is 10:34 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com