Existing switch will not shut off new fixture
I am replacing a kitchen fixture and I can't turn it off with the existing switch
The ceiling box has two wires going in. a black and white, as well as a black, white and red.
I did not connect the red to anything as it was not connected to the previous fixture.
The two blacks are capped,as are the whites but there is a white pigtail.
I put the blacks to the black from the fixture, I put the white (pigtail)to the white from the fixture.
All ground wires are connected.
The light works but I can't turn it off.
Anyone?