PC Review


Reply
Thread Tools Rate Thread

ActiveX controls only work in Single window

 
 
=?Utf-8?B?RXhjZWxEZXZlbG9wZXI=?=
Guest
Posts: n/a
 
      22nd Nov 2006
Hi,

I have a workbook where I have created multiple windows using the
ActiveWindow.NewWindow & Application.Windows.Arrange methods.

My problem is that the workbooks has several embedded
ActiveXControls(listboxes,commandbuttons,etc.). If you click on the control
in any of the windows other than the first window, the control doesn't
respond.

To use the control you must go to the first window and select the control
from there. At this point the control appears on the other windows with black
lines running diagonnally across it.

Is there any way to get around this behavior without having to move the
worksheet controls off the sheet and into a command bar or menu?

thanks,

Ben
 
Reply With Quote
 
 
 
 
NickHK
Guest
Posts: n/a
 
      23rd Nov 2006
Whilst this refers to Office97, I still see the same in Excel 2002.
http://support.microsoft.com/kb/168392
"For an ActiveX control to appear and function properly in multiple windows
or panes of the same document, the container application must support the
IViewObject interface. Because Word, Microsoft Excel, and PowerPoint do not
support this interface (as discussed in the previous section), the behavior
of an ActiveX control that is viewed in two different windows or panes of
the same document may be unpredictable."

Seems like you're out of luck.

NickHK

"ExcelDeveloper" <(E-Mail Removed)> wrote in message
news:2CBEFC58-2FAF-4F93-8AB1-(E-Mail Removed)...
> Hi,
>
> I have a workbook where I have created multiple windows using the
> ActiveWindow.NewWindow & Application.Windows.Arrange methods.
>
> My problem is that the workbooks has several embedded
> ActiveXControls(listboxes,commandbuttons,etc.). If you click on the

control
> in any of the windows other than the first window, the control doesn't
> respond.
>
> To use the control you must go to the first window and select the control
> from there. At this point the control appears on the other windows with

black
> lines running diagonnally across it.
>
> Is there any way to get around this behavior without having to move the
> worksheet controls off the sheet and into a command bar or menu?
>
> thanks,
>
> Ben



 
Reply With Quote
 
=?Utf-8?B?UGFwYURvcw==?=
Guest
Posts: n/a
 
      23rd Nov 2006
Maybe you can use the controls from the "Forms" toolbar instead of the
"Control ToolBox". They don't have that limitation (at least command buttons
and listboxes work ok)...
--
Regards,
Luc.

"Festina Lente"


"ExcelDeveloper" wrote:

> Hi,
>
> I have a workbook where I have created multiple windows using the
> ActiveWindow.NewWindow & Application.Windows.Arrange methods.
>
> My problem is that the workbooks has several embedded
> ActiveXControls(listboxes,commandbuttons,etc.). If you click on the control
> in any of the windows other than the first window, the control doesn't
> respond.
>
> To use the control you must go to the first window and select the control
> from there. At this point the control appears on the other windows with black
> lines running diagonnally across it.
>
> Is there any way to get around this behavior without having to move the
> worksheet controls off the sheet and into a command bar or menu?
>
> thanks,
>
> Ben

 
Reply With Quote
 
=?Utf-8?B?RXhjZWxEZXZlbG9wZXI=?=
Guest
Posts: n/a
 
      24th Nov 2006
That is a possible alternative, but you don't seem to be able to get at the
properties of the controls like you can with the controls in the control
toolbox. For example how can I name the control or use events like on focus
and click to fill a listbox. It seems like I can only assign a macro to the
controls.

"PapaDos" wrote:

> Maybe you can use the controls from the "Forms" toolbar instead of the
> "Control ToolBox". They don't have that limitation (at least command buttons
> and listboxes work ok)...
> --
> Regards,
> Luc.
>
> "Festina Lente"
>
>
> "ExcelDeveloper" wrote:
>
> > Hi,
> >
> > I have a workbook where I have created multiple windows using the
> > ActiveWindow.NewWindow & Application.Windows.Arrange methods.
> >
> > My problem is that the workbooks has several embedded
> > ActiveXControls(listboxes,commandbuttons,etc.). If you click on the control
> > in any of the windows other than the first window, the control doesn't
> > respond.
> >
> > To use the control you must go to the first window and select the control
> > from there. At this point the control appears on the other windows with black
> > lines running diagonnally across it.
> >
> > Is there any way to get around this behavior without having to move the
> > worksheet controls off the sheet and into a command bar or menu?
> >
> > thanks,
> >
> > Ben

 
Reply With Quote
 
=?Utf-8?B?UGFwYURvcw==?=
Guest
Posts: n/a
 
      24th Nov 2006
The "Forms" objects are not activeX objects, they don't have events or
dedicated VBA code or "properties" dialog. Depending on what you are doing,
they may not be powerful enough.
You can manipulate them a bit in VBA, they are considered "Shapes" of the
worksheet where they appear.

For example
debug.print Sheet1.shapes(1).name
will print the name of the first shape of Sheet1 in the immediate window.
You can use the name of the shape as an index to "shape" also.

Without knowing how you currently use your controls, I can't tell you if the
"Forms" controls are good enough for the job, but they are adequate in many
situations...




--
Regards,
Luc.

"Festina Lente"


"ExcelDeveloper" wrote:

> That is a possible alternative, but you don't seem to be able to get at the
> properties of the controls like you can with the controls in the control
> toolbox. For example how can I name the control or use events like on focus
> and click to fill a listbox. It seems like I can only assign a macro to the
> controls.
>
> "PapaDos" wrote:
>
> > Maybe you can use the controls from the "Forms" toolbar instead of the
> > "Control ToolBox". They don't have that limitation (at least command buttons
> > and listboxes work ok)...
> > --
> > Regards,
> > Luc.
> >
> > "Festina Lente"
> >
> >
> > "ExcelDeveloper" wrote:
> >
> > > Hi,
> > >
> > > I have a workbook where I have created multiple windows using the
> > > ActiveWindow.NewWindow & Application.Windows.Arrange methods.
> > >
> > > My problem is that the workbooks has several embedded
> > > ActiveXControls(listboxes,commandbuttons,etc.). If you click on the control
> > > in any of the windows other than the first window, the control doesn't
> > > respond.
> > >
> > > To use the control you must go to the first window and select the control
> > > from there. At this point the control appears on the other windows with black
> > > lines running diagonnally across it.
> > >
> > > Is there any way to get around this behavior without having to move the
> > > worksheet controls off the sheet and into a command bar or menu?
> > >
> > > thanks,
> > >
> > > Ben

 
Reply With Quote
 
=?Utf-8?B?RXhjZWxEZXZlbG9wZXI=?=
Guest
Posts: n/a
 
      24th Nov 2006
I often uses list and comboboxes which I populated programatically with events

"PapaDos" wrote:

> The "Forms" objects are not activeX objects, they don't have events or
> dedicated VBA code or "properties" dialog. Depending on what you are doing,
> they may not be powerful enough.
> You can manipulate them a bit in VBA, they are considered "Shapes" of the
> worksheet where they appear.
>
> For example
> debug.print Sheet1.shapes(1).name
> will print the name of the first shape of Sheet1 in the immediate window.
> You can use the name of the shape as an index to "shape" also.
>
> Without knowing how you currently use your controls, I can't tell you if the
> "Forms" controls are good enough for the job, but they are adequate in many
> situations...
>
>
>
>
> --
> Regards,
> Luc.
>
> "Festina Lente"
>
>
> "ExcelDeveloper" wrote:
>
> > That is a possible alternative, but you don't seem to be able to get at the
> > properties of the controls like you can with the controls in the control
> > toolbox. For example how can I name the control or use events like on focus
> > and click to fill a listbox. It seems like I can only assign a macro to the
> > controls.
> >
> > "PapaDos" wrote:
> >
> > > Maybe you can use the controls from the "Forms" toolbar instead of the
> > > "Control ToolBox". They don't have that limitation (at least command buttons
> > > and listboxes work ok)...
> > > --
> > > Regards,
> > > Luc.
> > >
> > > "Festina Lente"
> > >
> > >
> > > "ExcelDeveloper" wrote:
> > >
> > > > Hi,
> > > >
> > > > I have a workbook where I have created multiple windows using the
> > > > ActiveWindow.NewWindow & Application.Windows.Arrange methods.
> > > >
> > > > My problem is that the workbooks has several embedded
> > > > ActiveXControls(listboxes,commandbuttons,etc.). If you click on the control
> > > > in any of the windows other than the first window, the control doesn't
> > > > respond.
> > > >
> > > > To use the control you must go to the first window and select the control
> > > > from there. At this point the control appears on the other windows with black
> > > > lines running diagonnally across it.
> > > >
> > > > Is there any way to get around this behavior without having to move the
> > > > worksheet controls off the sheet and into a command bar or menu?
> > > >
> > > > thanks,
> > > >
> > > > Ben

 
Reply With Quote
 
=?Utf-8?B?UGFwYURvcw==?=
Guest
Posts: n/a
 
      24th Nov 2006
Well, it's your choice, you either live with the present behaviour or you try
to find a different set of controls that works...

--
Regards,
Luc.

"Festina Lente"


"ExcelDeveloper" wrote:

> I often uses list and comboboxes which I populated programatically with events
>
> "PapaDos" wrote:
>
> > The "Forms" objects are not activeX objects, they don't have events or
> > dedicated VBA code or "properties" dialog. Depending on what you are doing,
> > they may not be powerful enough.
> > You can manipulate them a bit in VBA, they are considered "Shapes" of the
> > worksheet where they appear.
> >
> > For example
> > debug.print Sheet1.shapes(1).name
> > will print the name of the first shape of Sheet1 in the immediate window.
> > You can use the name of the shape as an index to "shape" also.
> >
> > Without knowing how you currently use your controls, I can't tell you if the
> > "Forms" controls are good enough for the job, but they are adequate in many
> > situations...
> >
> >
> >
> >
> > --
> > Regards,
> > Luc.
> >
> > "Festina Lente"
> >
> >
> > "ExcelDeveloper" wrote:
> >
> > > That is a possible alternative, but you don't seem to be able to get at the
> > > properties of the controls like you can with the controls in the control
> > > toolbox. For example how can I name the control or use events like on focus
> > > and click to fill a listbox. It seems like I can only assign a macro to the
> > > controls.
> > >
> > > "PapaDos" wrote:
> > >
> > > > Maybe you can use the controls from the "Forms" toolbar instead of the
> > > > "Control ToolBox". They don't have that limitation (at least command buttons
> > > > and listboxes work ok)...
> > > > --
> > > > Regards,
> > > > Luc.
> > > >
> > > > "Festina Lente"
> > > >
> > > >
> > > > "ExcelDeveloper" wrote:
> > > >
> > > > > Hi,
> > > > >
> > > > > I have a workbook where I have created multiple windows using the
> > > > > ActiveWindow.NewWindow & Application.Windows.Arrange methods.
> > > > >
> > > > > My problem is that the workbooks has several embedded
> > > > > ActiveXControls(listboxes,commandbuttons,etc.). If you click on the control
> > > > > in any of the windows other than the first window, the control doesn't
> > > > > respond.
> > > > >
> > > > > To use the control you must go to the first window and select the control
> > > > > from there. At this point the control appears on the other windows with black
> > > > > lines running diagonnally across it.
> > > > >
> > > > > Is there any way to get around this behavior without having to move the
> > > > > worksheet controls off the sheet and into a command bar or menu?
> > > > >
> > > > > thanks,
> > > > >
> > > > > Ben

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Unable to get the window handle ... Windowless ActiveX controls are not supported Adam Benson Microsoft C# .NET 2 12th Jan 2010 04:42 PM
ActiveX controls work for one user but not another, please HELP! Kelvin Windows XP Security 1 16th Jan 2009 03:18 AM
ActiveX controls don't work in IE 6.0 on Windows XP Pro SP2 =?Utf-8?B?U2hpbW9uIFNpbQ==?= Windows XP Internet Explorer 4 17th Aug 2006 11:55 PM
ActiveX controls that work =?Utf-8?B?bWlrZV9sX21vb3JlQG1zbi5jb20=?= Microsoft Access Macros 1 7th Apr 2005 11:33 PM
activex controls in child window insomniac Microsoft VC .NET 0 15th Sep 2003 03:20 AM


Features
 

Advertising
 

Newsgroups
 


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