Yes, the funds do have to be in cash at the time of the application. If it's cash within a 401k account which allows you instant access withdrawal, with or without a penalty, this is acceptable.
If the investment is still in stocks and shares within the account, that will not work.
It used to be that you had to have held the cash (as opposed to the investments) for 6 months but they changed it so that if you convert those investments to cash prior to the application they would accept that, in the same way as you can use proceeds from the sale of a house you have owned for longer than 6 months.
The key points are 1-cash, 2-instant access.