Home |
Search |
Today's Posts |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Try this
Dim objFrame As Frame Dim objTextBox As Control Set objFrame = ActiveSheet.OLEObjects.Add(ClassType:="Forms.Frame .1").Object Set objTextBox = objFrame.Controls.Add("Forms.Textbox.1") On 3/17/2010 12:50 PM, sarndt wrote: Well - I've played with this further. I can add a control toolbox frame to the worksheet in display mode, but I can't add it using the code below in the Worksheet_change event where I trying to add the frame. Set objFrame = Activesheet.OLEObjects.Add(classtype:="MSForms.Fra me") Steve ================= "sarndt" wrote: In VBA Code behind a worksheet Dim objFrame As OleObject Dim objTextBox As OLEObject Set objFrame = ActiveSheet.OLEObjects.Add(ClassType:="Forms.Frame .1") Set objTextBox = ActiveSheet.OLEObjects(objFrame).Add(ClassType:="F orms.Textbox.1") Frame is created. But Textbox statement errors out - and doesn't get created inside of Frame Thanks Steve |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
What do I do wrong [Excuses pushing the wrong key combination earlier] | Excel Programming | |||
Is there something wrong with this? | Excel Programming | |||
What's wrong with this ?? | Excel Programming | |||
Insert Calculated Field (wrong Qty*Price = wrong Amount) | Excel Discussion (Misc queries) | |||
Please Tell Me What I Am Doing Wrong | Excel Programming |