Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Including ActiveX Controls in Names Range Selection
I hope this is a quick. I'd like a named range selection to include ActiveX
controls within the range so I can copy the range elsewhere. What I've found is if I reference the range as "B77:AM99" the ActiveX controls are included in the selection. If, however, I create a named range defined as "$B$77:$AM$99" then the ActiveX controls are not included in the selection. The Placement property of the controls is set to 2. I'd prefer the named range approach if possible. Any suggestions? Thanks! -- Jack << |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Including ActiveX Controls in Names Range Selection
I couldn't duplicate this in xl2003.
I had commandbuttons from the control toolbox in the middle of a named range and the middle of an unnamed range. This code didn't copy the commandbuttons: Worksheets("Sheet1").Range("Test1").Copy _ Destination:=Worksheets("Sheet2").Range("a1") Worksheets("Sheet1").Range("f1:k10").Copy _ Destination:=Worksheets("Sheet2").Range("g1") Jack wrote: I hope this is a quick. I'd like a named range selection to include ActiveX controls within the range so I can copy the range elsewhere. What I've found is if I reference the range as "B77:AM99" the ActiveX controls are included in the selection. If, however, I create a named range defined as "$B$77:$AM$99" then the ActiveX controls are not included in the selection. The Placement property of the controls is set to 2. I'd prefer the named range approach if possible. Any suggestions? Thanks! -- Jack << -- Dave Peterson |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Including ActiveX Controls in Names Range Selection
Ps. I tried with both "move and size with cells" and "move but don't size with
cells". Jack wrote: I hope this is a quick. I'd like a named range selection to include ActiveX controls within the range so I can copy the range elsewhere. What I've found is if I reference the range as "B77:AM99" the ActiveX controls are included in the selection. If, however, I create a named range defined as "$B$77:$AM$99" then the ActiveX controls are not included in the selection. The Placement property of the controls is set to 2. I'd prefer the named range approach if possible. Any suggestions? Thanks! -- Jack << -- Dave Peterson |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Including ActiveX Controls in Names Range Selection
I got the same results as Dave.
However, if you use a control from the "Forms" toolbar the control is included with the range if you keep the copied data/object off the clipboard. This works... Range("AreaTwo").Copy Range("G1") This does not... Range("AreaTwo").Copy Range("G1").PasteSpecial -- Jim Cone San Francisco, USA http://www.realezsites.com/bus/primitivesoftware (Excel Add-ins / Excel Programming) "Jack" wrote in message I hope this is a quick. I'd like a named range selection to include ActiveX controls within the range so I can copy the range elsewhere. What I've found is if I reference the range as "B77:AM99" the ActiveX controls are included in the selection. If, however, I create a named range defined as "$B$77:$AM$99" then the ActiveX controls are not included in the selection. The Placement property of the controls is set to 2. I'd prefer the named range approach if possible. Any suggestions? Thanks!-- Jack << |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Including ActiveX Controls in Names Range Selection
Hmm....This is very odd. You're right. I'm actually getting the same results
as you. I can copy and paste manually and the button copies with the selection. If I record the same steps as a macro and execute the macro, the button is not included. I'm not sure why the different behavior. I'll have to find some other workaround. Thanks so much for your time! -- Jack << "Dave Peterson" wrote: Ps. I tried with both "move and size with cells" and "move but don't size with cells". Jack wrote: I hope this is a quick. I'd like a named range selection to include ActiveX controls within the range so I can copy the range elsewhere. What I've found is if I reference the range as "B77:AM99" the ActiveX controls are included in the selection. If, however, I create a named range defined as "$B$77:$AM$99" then the ActiveX controls are not included in the selection. The Placement property of the controls is set to 2. I'd prefer the named range approach if possible. Any suggestions? Thanks! -- Jack << -- Dave Peterson |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
Including ActiveX Controls in Names Range Selection
Jim,
As I played with it more, I'm finding irregular results, most in line with what you and Dave reported. It works fine for me if I manually copy and paste but fails on the playback of a macro recorded from a successful manual copy and paste. Alas, I've got to have more control over the button than the "forms" button provides, so I'm stuck with the ActiveX version. Thanks so much for your time! -- Jack << "Jim Cone" wrote: I got the same results as Dave. However, if you use a control from the "Forms" toolbar the control is included with the range if you keep the copied data/object off the clipboard. This works... Range("AreaTwo").Copy Range("G1") This does not... Range("AreaTwo").Copy Range("G1").PasteSpecial -- Jim Cone San Francisco, USA http://www.realezsites.com/bus/primitivesoftware (Excel Add-ins / Excel Programming) "Jack" wrote in message I hope this is a quick. I'd like a named range selection to include ActiveX controls within the range so I can copy the range elsewhere. What I've found is if I reference the range as "B77:AM99" the ActiveX controls are included in the selection. If, however, I create a named range defined as "$B$77:$AM$99" then the ActiveX controls are not included in the selection. The Placement property of the controls is set to 2. I'd prefer the named range approach if possible. Any suggestions? Thanks!-- Jack << |
#7
Posted to microsoft.public.excel.programming
|
|||
|
|||
Including ActiveX Controls in Names Range Selection
Just a complete wild guess...
Close excel and clean up your windows temp folder. Lots of programs store junk there (like excel) and if it gets large, it can confuse excel. Close excel Windows start button|Run type: %temp% and clean up everything you can Then back to excel to test. Jack wrote: Hmm....This is very odd. You're right. I'm actually getting the same results as you. I can copy and paste manually and the button copies with the selection. If I record the same steps as a macro and execute the macro, the button is not included. I'm not sure why the different behavior. I'll have to find some other workaround. Thanks so much for your time! -- Jack << "Dave Peterson" wrote: Ps. I tried with both "move and size with cells" and "move but don't size with cells". Jack wrote: I hope this is a quick. I'd like a named range selection to include ActiveX controls within the range so I can copy the range elsewhere. What I've found is if I reference the range as "B77:AM99" the ActiveX controls are included in the selection. If, however, I create a named range defined as "$B$77:$AM$99" then the ActiveX controls are not included in the selection. The Placement property of the controls is set to 2. I'd prefer the named range approach if possible. Any suggestions? Thanks! -- Jack << -- Dave Peterson -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
ActiveX Controls | Excel Discussion (Misc queries) | |||
Tab between ActiveX controls | Excel Discussion (Misc queries) | |||
activex controls? | Excel Programming | |||
ActiveX Controls vs Form Controls | Excel Discussion (Misc queries) | |||
activex controls | Excel Programming |