None of the solutions you suggest works. But I find a way :
I declare the main_Vbox as a global variable, not a part of a structure. It's implies some adjustments in my code but it will work just fine!
Thank for your quick answer, it led me to a solution.
First of all, Great Work! It's exactly what I needed.
I have an issue :
I created a GUI. Using check-boxes, I want to resize the component of an Vbox but I have an error message.
I create the Vbox an put some Hboxes in it.
In the callback function of the check-boxes, I wrote :
set(GUI_data.main_Vbox, 'Sizes', [...]); %GUI_data is the global variable that handles all GUI components.
The error message is :
??? Error using ==> set
There is no 'sizes' property in the 'uipanel' class.
Error in ==> callback_function at 174
set(GUI_data.main_Vbox, 'sizes', sizes);
??? Error while evaluating uicontrol Callback
Apparently, in other functions, a Vbox in see as a uipanel. How can I change the 'Sizes' property from outside the function I create it ?