Debug ActiveX object
Thank's for infomation
"onedaywhen" wrote in message
om...
ActiveX controls are from the Controls ToolBox, not the Forms toolbar
(but if you are adding them dynamically you are using neither
toolbar!). If you really do mean ActiveX controls then no, you can't
step through your code because OLEObjects that get added
programmatically aren't fully mature in the eyes of the code engine
(to quote Excel MVP, Dick Kusleika) at this time.
As a workaround, you could strategically add lines of code to print
information to the VBE Immediate Window at run-time using Debug.Print
i.e.
Sub test()
Dim oOle As Object
Set oOle = Sheet1.OLEObjects.Add("Forms.OptionButton.1")
Debug.Print oOle.Name
oOle.Name = "NewNameHere"
Debug.Print oOle.Name
End Sub
--
"Carlos" wrote in message
...
Hello
I add in worksheet one combobox (Forms not Control ToolBox) with the
properties set via code.
I need to debug the code step by step in VBA IDE, but receved the
message
("Can't enter break code at this time.") when the code enter in the
combo
box properties.
Is a way to Debug the code step by step in VBA IDE
thank's
------------------------------------
maybe humans, but still ANIMALS
------------------------------------
|