The code you linked to works like a charm, thank you! I have managed to get the model to take a value from the excel sheet, put it into an expression, update the model according to the new expression, get the next value from the spreadsheet, update end so on. I have spent half a day looking for...