T-SQL syntax does not allow you to use a column defined in the SELECT list (in your case, the 'Out' column) anywhere else in that query except in the ORDER BY clause. This is because of the logical sequence in which SQL Engine processes the query. If you are interested in logical query processing phases, see here.
So change your query to use the actual expression for 'Out' in the where clause as well
SELECT tblarInvoice.InvoiceNumber ,
DATEDIFF(dd, InvoiceDueDate, GETDATE()) AS 'Out'
WHERE Status = 'open'
AND DATEDIFF(dd, InvoiceDueDate, GETDATE()) > 40