Search code examples
iosobjective-cxcodeuislider

UISlider with single bar color


I cant believe i cant find answer online - this is what im trying to achieve- Single color for the UISlider bar(no matter where the thumb is)

Dont mind the BG color

s

, but all i can change is one size of the bar(Tint color i guess) :\

s

Any ideas how can i achieve single color all the way?


Solution

  • set

    choice -1

    yoursliderName.minimumTrackTintColor = [UIColor blueColor];
    yoursliderName.maximumTrackTintColor = [UIColor blueColor];
    

    if choice no 1 is not work

    choice - 2

    see this already answered in stack overflow answer

    additional Reference