Click here to Skip to main content
15,888,286 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi everybody,
I had create a new project with a taskpanel in Excel using VSTO in Vb.net.
I had a problem when set the width of taskpanel when show taskpanel position:
.DockPosition = Microsoft.Office.Core.MsoCTPDockPosition.msoCTPDockPositionLeft 
or 
.DockPosition = Microsoft.Office.Core.MsoCTPDockPosition.mmsoCTPDockPositionRight.

I want to set taskpanel width < 50 but seem i can't set my taskpanel width < default minimum taskpanel width (~50).
I think there must be some way to solve this?


Can you please let me know if we there is a way to change the width through code or configuration?

Thanks

What I have tried:

How to set My CustomTaskPane width < Minimum of Default Taskpane width in VSTO using VB.net
Posted
Updated 24-Oct-17 9:12am

1 solution

Check this: CustomTaskPane.Width Property (Microsoft.Office.Tools)[^]

MSDN wrote:
The minimum width depends on several factors, and can change in future releases of Microsoft Office. If you try to set the Width property to a value that is less than the minimum width, the application will automatically reassign the Width property to the minimum width.
 
Share this answer
 
v2
Comments
tannhuong 25-Oct-17 21:06pm    
I had try with panel of Microsoft (Word: Navigation Pane and Excel) and recived the same results. Can be this is default of panel of Microsoft and we can't change it at the present. I will change my designt instead of find solved. Hope in future Microsoft will change it.
Thanks Maciej Los. :)
Maciej Los 26-Oct-17 5:07am    
You're very welcome.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900