Question

HI,
I have a problem in dynamically adding horizontal and vertical scrollbar to a view . Basically the application zoom in and zoom out an image. I want to put horizontal and vertical scrollbar dynamically whenever view is out bounds. i.e. when zoom in is click and view is gonna out of bond, then it automatically add scrollbar. I am using these two methods but they didn't work correctly.
        setVerticalScrollBarEnabled(true);
        setHorizontalScrollBarEnabled(true);
Does i have to put these methods inside onDraw(Canvas canvas) method of the view?
Note: I am not creating view using xml file. I am creating view using a class which is inherited from View.
Thank you!!

No correct solution

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top