Invisible UI button?

slushpuppyslushpuppy Member ✭✭

![](htt ps://us.v-cdn.net/5019960/uploads/editor/w4/41t66i831124.png "")

I am not sure this is the case. This is also pertinent to the invisible back button found in navigation controller

Answers

  • LandLuLandLu Member, Xamarin Team Xamurai

    Do you mean the button's title dose't show up, but you can fire the button's click event? How did you put this button on the storyboard, can you share some details and code related? Also try to clean you project, does this happen on a blank project?

  • slushpuppyslushpuppy Member ✭✭

    @LandLu said:
    Do you mean the button's title dose't show up, but you can fire the button's click event? How did you put this button on the storyboard, can you share some details and code related? Also try to clean you project, does this happen on a blank project?

    Hey, thanks for the tips! Yes, the button functionality works. Button title shows up on a blank project too.

    I just tried changing the colors on the UIButton and the title shows up. Interesting. Where could I find the default theme of the project to change the original color of the buttons??

  • slushpuppyslushpuppy Member ✭✭

    I placed this code in viewdidload method to fix the issue:

            var navTintColor = UINavigationBar.Appearance.TintColor;
            UIButton.AppearanceWhenContainedIn(typeof(UINavigationBar)).TintColor = navTintColor;
    

    Still not the ideal situation however.

  • LandLuLandLu Member, Xamarin Team Xamurai

    @slushpuppy Have you changed the button's TintColor somewhere else? Your code just set the tintColor of global buttons all in your project to the navigation bar's tintColor. Try to post some code how do you construct your button.

  • slushpuppyslushpuppy Member ✭✭

    @LandLu said:
    @slushpuppy Have you changed the button's TintColor somewhere else? Your code just set the tintColor of global buttons all in your project to the navigation bar's tintColor. Try to post some code how do you construct your button.

    Hi Landlu, Thanks for the reply. I created the button simply by using a drag and drop in the IOS designer- however I taken over this project after someone else, and I scanned the .cs files already, there's no obvious routine or codes that edit the color of the label of the button.

    A quick debug shows that UINavigationBar.Appearance.TintColor is not set to any colors

Sign In or Register to comment.