b4x-de Active Member Licensed User Longtime User Dec 20, 2020 #1 I know that I can change the orientation of a xCustomListView by setting it in the designer. But is there also a way to set it at runtime (in code or via designer script)? I'm asking because I want to change from vertical scroll to horizontal scroll when device orientation changes. Thanks, Thomas
I know that I can change the orientation of a xCustomListView by setting it in the designer. But is there also a way to set it at runtime (in code or via designer script)? I'm asking because I want to change from vertical scroll to horizontal scroll when device orientation changes. Thanks, Thomas
Erel B4X founder Staff member Licensed User Longtime User Dec 21, 2020 #2 While I haven't tried it, it might work in B4i (it will not work in B4A). Clear the list, set CLV.Horizontal and call clv.Base_Resize. Upvote 0
While I haven't tried it, it might work in B4i (it will not work in B4A). Clear the list, set CLV.Horizontal and call clv.Base_Resize.
b4x-de Active Member Licensed User Longtime User Dec 21, 2020 #3 Thank you. Unfortunately I can find any property or operation to set Horizontal or Vertical orientation from code in B4i. It is also not available when I access a CLV via AsView or via GetBase. I did not find anything in the documentation. Maybe I’m using the wrong version, it is the one contained in the current XUI Views Version 2.43. How can I set CLV orientation in this version? Thanks, Thomas Upvote 0
Thank you. Unfortunately I can find any property or operation to set Horizontal or Vertical orientation from code in B4i. It is also not available when I access a CLV via AsView or via GetBase. I did not find anything in the documentation. Maybe I’m using the wrong version, it is the one contained in the current XUI Views Version 2.43. How can I set CLV orientation in this version? Thanks, Thomas
Erel B4X founder Staff member Licensed User Longtime User Dec 22, 2020 #4 You are correct. The field is private in the library. Use this: Code: Copy Dim no As NativeObject = CustomListView1 'ignore no.SetField("__horizontal", False) Upvote 0
You are correct. The field is private in the library. Use this: Code: Copy Dim no As NativeObject = CustomListView1 'ignore no.SetField("__horizontal", False)