MitchBu Well-Known Member Licensed User Longtime User Dec 21, 2020 #1 From the same source, I generate 4 different apps: Check Printer+, Check Printer Free, Check Writer Pro, Check Writer Free. Is it possible to change Tab Bar icons and tag in code ? That would allow me to change the tab bar content according to the apps. For instance by adding the shopping cart icon in the free apps.
From the same source, I generate 4 different apps: Check Printer+, Check Printer Free, Check Writer Pro, Check Writer Free. Is it possible to change Tab Bar icons and tag in code ? That would allow me to change the tab bar content according to the apps. For instance by adding the shopping cart icon in the free apps.
Erel B4X founder Staff member Licensed User Longtime User Dec 21, 2020 #2 The best solution is to create layout files with only the tab buttons. This way you can load the correct one based on the app version. You can also create them programmatically: Code: Copy Dim bb1, bb2, bb3 As BarButton bb1.InitializeText("111", "aqwdsdasd") bb2.InitializeSystem(bb2.ITEM_FLEXIBLE_SPACE, "") bb3.InitializeText("as222", "asdasd") Page1.ToolbarButtons = Array(bb1, bb2, bb3) Upvote 0
The best solution is to create layout files with only the tab buttons. This way you can load the correct one based on the app version. You can also create them programmatically: Code: Copy Dim bb1, bb2, bb3 As BarButton bb1.InitializeText("111", "aqwdsdasd") bb2.InitializeSystem(bb2.ITEM_FLEXIBLE_SPACE, "") bb3.InitializeText("as222", "asdasd") Page1.ToolbarButtons = Array(bb1, bb2, bb3)
MitchBu Well-Known Member Licensed User Longtime User Dec 29, 2020 #4 Hi @Erel , sorry to bug you, but how do I place icons on the tab bar with this method ? Your example shows only text content. Thank you. Last edited: Dec 29, 2020 Upvote 0
Hi @Erel , sorry to bug you, but how do I place icons on the tab bar with this method ? Your example shows only text content. Thank you.
Erel B4X founder Staff member Licensed User Longtime User Dec 29, 2020 #5 Code: Copy Dim bb As BarButton bb.InitializeSystem(bb.ITEM_CAMERA, "tag") Or bb.InitializeBitmap for non-system icons. Upvote 0
Code: Copy Dim bb As BarButton bb.InitializeSystem(bb.ITEM_CAMERA, "tag") Or bb.InitializeBitmap for non-system icons.
MitchBu Well-Known Member Licensed User Longtime User Dec 29, 2020 #6 Great. Works perfectly. Thank you Erel Upvote 0