Android Question Horizontal scroll in b4xview?

ViMeAv ICT

Member
Licensed User
Longtime User
I use the example with a customlistview and b4xview to scroll through images.
This works fine, scrolling up and down.
But I need a possibility to sdcroll through images from left to right.
Is this possible with this combination or only with the old scrollview2d?
 

ViMeAv ICT

Member
Licensed User
Longtime User
How can I use these functions?
  • Initialize (Callback As Object, EventName As String)
  • Initialize2 (Callback As Object, EventName As String, PanelParent As B4XView, Width As Int, Height As Int)
When I left callback open, i get an error message, "object should first be initialized"
Is there an example with the correct syntax of these functions?
I don't want to use the designer.
 
Upvote 0

Star-Dust

Expert
Licensed User
Longtime User
How can I use these functions?
  • Initialize (Callback As Object, EventName As String)
  • Initialize2 (Callback As Object, EventName As String, PanelParent As B4XView, Width As Int, Height As Int)
When I left callback open, i get an error message, "object should first be initialized"
Is there an example with the correct syntax of these functions?
I don't want to use the designer.
Not using Initialize2 creates a lot of problems. You have to insert the scrollView from Design and it is therefore not necessary to initialize.
 
Upvote 0

ViMeAv ICT

Member
Licensed User
Longtime User
When I insert the scrollview from Design I get an error when i use:
XUIScrollView1.width = 300
XUIScrollView1.Height = 500
So I wanted to try with Initialize(), but that did not work also.
 
Upvote 0

Star-Dust

Expert
Licensed User
Longtime User
When I insert the scrollview from Design I get an error when i use:
XUIScrollView1.width = 300
XUIScrollView1.Height = 500
So I wanted to try with Initialize(), but that did not work also.
Che errore? Hai usato ScrollView.GetBase.Width ?
 
Upvote 0

ViMeAv ICT

Member
Licensed User
Longtime User
error.png
 
Upvote 0

Star-Dust

Expert
Licensed User
Longtime User
There was a bugs. Download version 0.13
 
Upvote 0

ViMeAv ICT

Member
Licensed User
Longtime User
Thanks!
I see you made many libs.

Another question: I'm now using your XUIScrollView but maybe it's not the best option.

I am actually looking for a way to scroll (horizontally) through images. (images of categories)
On every image there should be a label with the name of the categorie. (no problem)
Also maybe using the long/short click (gridImage lib) to open a info page or open a new view with all products.
(and clicking every product leads to page with bigger product photo and fields for description, stock value, etc.
Also possibility to enter amount, discount, price, etc.
Maybe the gridimage functions better, but I guess no horizontal scrolling.

Is the XUIScrollView the best option?
I use .createpanel, do you know which event will be raised, when clicking on every picture.
I expected a Categorie click_event but nothing happened.
 
Upvote 0
Top