Dishwasher not filling

I just purchased a used dishwasher, I hooked it up and it is not filling. When I set the cycle to start the drain pump activates and if manually filled with water drains. After this the dishwasher attempts a clean cycle and again if manually filled with water will function. Can anyone please advise on what might be wrong and what can be done to repair it.

Thanks

Matt

Are you sure the water is on ? Is the water valve getting power when it’s supposed to be ?