It's a limitation of Excel as described in that article; don't know if Excel
implements the required interface in the 2007 version, but none before
AFAIK.
The Forms controls are not ActiveX and hence interface and other COM
constructs do not apply.
I don't use VSTO, but in VBA you can add a Forms button with :
ActiveSheet.Buttons.Add(481.5, 9, 102, 58.5).Select
NickHK
"DenisKa" wrote in message
...
Thanks.
My problem is the following: I use VS 2005 and VSTO, MS Office 2003 Pro
SP1,
and drop some buttons to Excel's sheet. If freeze panes are activated -
all
buttons behind screen's bounds are disabled (just a picture). If freezing
bound crosses a button - it is the strange situation I have desribed
before
(a half of a button is OK, second one is not). Seems to your case very
much.
Does this limitation still go for 2003 and is this same issue for two
cases?
Can it be an explanation: "When a Windows Forms control is added to a
Microsoft Office Word or Microsoft Office Excel document, Microsoft Visual
Studio 2005 Tools for the Microsoft Office System embeds an ActiveX
control
that then hosts the Windows Forms control in the document. The Windows
Forms
control is not embedded directly in the document"? Looks like same ActiveX
problem...
TIA
"NickHK" wrote:
A limitation of Excel :
<From an earlier post
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.
</From an earlier post
Not this only applies to ActiveX. If you can use the controls from the
Forms
tool box, there is no issue.
NickHK
"DenisKa" wrote in message
...
Hi
When I add some controls to sheet (e.g. buttons), and use 'Freeze
panes'
option then some controls become disabled. E.g.: a half of a button
can be
enabled and clicked, second one is like a picture. Why does this
happen?
TIA