Crate Training And Litter Box Question.?

I have a Westie who is being crate trained. I live in a high-rise so I would like to also get him used to using a litter box. Is it alright to have the litter box inside the crate? The rest of the crate would be covered by his bed area.

How Can You Train A 8 Wk Old Westie To Go In A Doggie Litter Box?

Every time she poops i run to the litter box but she stops pooping and same with pee plz som1 help me :-(