ReceiptBox has no way of knowing what type of object is being stored in it. You will need to cast it as such
var subTotal = ReceiptBox.Items.Cast<Hardware>().Sum(item => item.Price);
Not too familiar with WinForms, but it looks like a better way of doing this would be utilizing ListBox.DataSource Property
Here is a stackoverflow thread on this matter