resize/rescale user control in ActiveX container

S

Sunny

This is repost, as it seems I had some problems with my antispam alias.
Lets hope it is solved.

Now, here's the repost:

Hi,
I have a user control, which I use in COM application. To be more
specific, I have Outlook 2000 add-in (C#. framework 1.1 SP 1).

So, you can attach your own Options page to Outlook's Tools/Options.

I have created a user control for that, and it displays and acts as
intended.

The only problem is, when it runs on a machine with different
resolution, and different system font size, it does not rescale
(autoscale) as regular forms does.

If I switch my windows to Large Fonts, then everything enlarges :), all
forms are rescaled, etc. So does the box Outlook opens when you select
Tools/Options. All property pages there are OK, only mine is not
rescaled, and labels become multiline, all controls a far away from the
right end, etc.

Now, the question:

How to get the parent size, so I can manually rescale and reposition my
controls. (Control.Parent does not work, as this is ActiveX control
hosted in Outlook).

Or, better, is there some automatic feature, like AutoScale in winforms?

Thanks
Sunny
 
J

Jeffrey Tan[MSFT]

Hi Sunny,

We have reviewed your post, currently, we will spend some time to do some
research on this issue, we will reply to you ASAP. Thanks for your
understanding.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
 
J

Jeffrey Tan[MSFT]

Hi Sunny,

Sorry for letting you wait for so long.

Actually, currently for .Net 1.1, the only officially supported ActiveX
containers for .Net Control are Windows Forms, Microsoft Foundation Classes
(MFC) 7.x, and Internet Explorer 5.01 and later versions, which does not
container Office applications. This is documented in the KB below:
"ActiveX control containers that support .NET controls"
http://support.microsoft.com/default.aspx?scid=KB;EN-US;311334

I also have contacted our product team, from the feedback, I was told that
we don¡¯t support .NET controls in non-.net containers since the managed /
unmanaged message pumps are different. And except for the above 3 type of
activeX containers, other application is not fully tested for hosting .Net
Control, and you may result in some un-expected strange behaviors.

Hope this information helps.
=============================================
Thank you for your patience and cooperation. If you have any questions or
concerns, please feel free to post it in the group. I am standing by to be
of assistance.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
 
S

Sunny

Jeffrey said:
Hi Sunny,

Sorry for letting you wait for so long.

Actually, currently for .Net 1.1, the only officially supported ActiveX
containers for .Net Control are Windows Forms, Microsoft Foundation
Classes (MFC) 7.x, and Internet Explorer 5.01 and later versions, which
does not container Office applications. This is documented in the KB
below: "ActiveX control containers that support .NET controls"
http://support.microsoft.com/default.aspx?scid=KB;EN-US;311334

I also have contacted our product team, from the feedback, I was told that
we don't support .NET controls in non-.net containers since the managed /
unmanaged message pumps are different. And except for the above 3 type of
activeX containers, other application is not fully tested for hosting .Net
Control, and you may result in some un-expected strange behaviors.

Hope this information helps.
=============================================
Thank you for your patience and cooperation. If you have any questions or
concerns, please feel free to post it in the group. I am standing by to be
of assistance.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.


Hi Jeffrey,
not exactly what I need but ...
Anyway, as it works OK in normal situation (i.e. using "small fonts" for the
desktop), I was kind-a hoping to make it run.

Most probably I'll create my own, managed form to set my options. But it was
so beautiful, when it was in Tools/Options ... huh

Sunny
 
J

Jeffrey Tan[MSFT]

Hi Sunny,

Thanks for your feedback!

Yes, I see your concern. Once upon a time, I meet a customer who made a COM
container to host the .Net User Control, everything works well, but after
sometime there comes a strange problem(the details I can not remember),
which we can not work out. Then, I find that this issue also fall into the
un-supported senario in that KB. So we strongly not support you do
something like this, and any issue arises from this senario is not official
supported. Thanks for your understanding.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top