Bit of a long one, and I really need help with this. I am sure there will be a way of doing it, but it's beyond me.

I have a spreadsheet that I have numerous tabs in, for daily record on hours worked for both labourers, and machines, which is then is totalled at the bottom to give me a weekly cost. The problem comes when I need to allocate the daily costs to different cost codes.

What I would like to do is to create a formula that picks up the hours in each row, calculates it with the appropriate cost, then adds in all together, so I get a “lump sum” daily figure cost for that day.

I can provide an example sheet for anyone to see that may be able to help me, as trying to explain is rather hard!