ScrollableBar bean

Hi there,

I am attaching here a bean called ScrollableBar bean. I have got this from internet. I have attached here (with source code). I copied the bean to bean folder of servoy. But when I tried to place the bean to the form I could not find it in the bean list.

Can you please unzip the jar and help me check the source/manifest and also the bean is package correctly or not.

Thanks a lot!!

ScrollableBar.jar (17.1 KB)

I added a default constructor and modified the manifest a bit. It now shows in the beans list, but I’m not sure its going to do you any good. The bean was designed in a way that makes it difficult to use in Servoy.

From looking at the source it seems the ScrollableBar is a widget that will add little scrolling arrows to a component when it gets too small instead of the big scrollbar that Swing usually adds for scroll support. The problem you will have is that Servoy’s builder tool doesn’t automagically add components to other containers… it just lays out components and beans as you put them on the form. I suppose you could get the effect you are after by doing some editing to the bean, but it might be more useful to put in a feature request to Servoy to build this type of support into the developer - maybe even building in this ScrollableBar component support. It sounds like a cool component.

Anyway, best of luck… here’s the modified bean.

ScrollableBar.jar (45.2 KB)

Hello!

Thanks a lot for your help. I have seen you have added a default constructor. Now I can place bean in the form now. But it is not useful to me at all. I am new to java language. But I will give it a try on working around to be able to use in Servoy. I have tried the following code:

var scr = elements.bean_555;
scr.setComponent(elements.tab1); //*** tab1 is servoy tabPanel which used to be a Component object
scr.updateUI();

But actually it neither throw an error nor set the object object properly. If you can throw me some ideas on fixing the bean that would be a real help to me.

Thanks!