Rusty Well-Known Member Licensed User Longtime User Jan 4, 2011 #1 I would like to change a tabhost tab image programatically. I've tried Dim BG As Bitmap bg.Initialize(File.DirAssets, "Done.png") tabhost1.CurrentTab = 1 tabhost1.SetBackgroundImage(bg) this changes the whole tabhost background. Any suggestions. I would like to do this to be able to change the tab image based upon completion of tasks within each tab. Thanks,
I would like to change a tabhost tab image programatically. I've tried Dim BG As Bitmap bg.Initialize(File.DirAssets, "Done.png") tabhost1.CurrentTab = 1 tabhost1.SetBackgroundImage(bg) this changes the whole tabhost background. Any suggestions. I would like to do this to be able to change the tab image based upon completion of tasks within each tab. Thanks,
Erel B4X founder Staff member Licensed User Longtime User Jan 5, 2011 #2 Instead of using AddTab you should use AddTab2 and add a panel. You can load the layout file to this panel. Later you will be able to change the panels backgrounds. Upvote 0
Instead of using AddTab you should use AddTab2 and add a panel. You can load the layout file to this panel. Later you will be able to change the panels backgrounds.
Rusty Well-Known Member Licensed User Longtime User Jan 6, 2011 #3 Tab image change Thanks, Erel. I was able to add the image to the tab "form", but I want to add/change the "icon" or image within the actual tab itself, not the body of the tab "form". Any suggestions. (for example, in your tabhost1 example you show a microphone within the tab, I'd like to be able to dynamically change this image) Thanks Upvote 0
Tab image change Thanks, Erel. I was able to add the image to the tab "form", but I want to add/change the "icon" or image within the actual tab itself, not the body of the tab "form". Any suggestions. (for example, in your tabhost1 example you show a microphone within the tab, I'd like to be able to dynamically change this image) Thanks
Erel B4X founder Staff member Licensed User Longtime User Jan 7, 2011 #4 The tab icon cannot be changed dynamically. Upvote 0
gapi Active Member Licensed User Longtime User Jun 1, 2012 #5 Erel said: Instead of using AddTab you should use AddTab2 and add a panel. You can load the layout file to this panel. Later you will be able to change the panels backgrounds. Click to expand... Hi Erel I use AddTab2 with panel inside, now how can change tabHost background color ? It's orange ... I tried with this code: Code: Copy TabHost1.AddTabWithIcon2("", bmp3, bmp4, Panel1) TabHost1.AddTabWithIcon2("", bmp5, bmp6, Panel1) TabHost1.Color = Colors.RGB(0,153,204) become blue on board and orange inside !!! tnx Upvote 0
Erel said: Instead of using AddTab you should use AddTab2 and add a panel. You can load the layout file to this panel. Later you will be able to change the panels backgrounds. Click to expand... Hi Erel I use AddTab2 with panel inside, now how can change tabHost background color ? It's orange ... I tried with this code: Code: Copy TabHost1.AddTabWithIcon2("", bmp3, bmp4, Panel1) TabHost1.AddTabWithIcon2("", bmp5, bmp6, Panel1) TabHost1.Color = Colors.RGB(0,153,204) become blue on board and orange inside !!! tnx
Erel B4X founder Staff member Licensed User Longtime User Jun 3, 2012 #6 Have you tried changing the panel background color? Upvote 0
gapi Active Member Licensed User Longtime User Jun 4, 2012 #7 Erel said: Have you tried changing the panel background color? Click to expand... In designer or in code ... in designer same effect (don't change color) ! tnx Last edited: Jun 4, 2012 Upvote 0
Erel said: Have you tried changing the panel background color? Click to expand... In designer or in code ... in designer same effect (don't change color) ! tnx
Erel B4X founder Staff member Licensed User Longtime User Jun 6, 2012 #8 Do you want to change the tab indicators colors? In that case you should use TabHostExtra library. Upvote 0