Hi Sue
A question on your use case - are you always selecting the first material for the substitution, i.e. there is only one to select?
I don't have that pop-up to try this myself, so in general I would:
(1) look at the sales order line item (or line item details). Does it show the substituted material selected somewhere? If so, I would try to download from there.
(2) If not, go into expert mode and find where the substitution pop-up occurs, and then copy a row from a field that is captured into that section of the script, manually updating the technical field name, which you have. Since it's a grid, you will have to add (01) at the end - assuming it's always the first row. You can try to download it that way.
(3) look for a BAPI to create a sales order that handles substitution
(4)If that doesn't work, GUI scripting mode is not ideal, but it could capture a read-only field for download.
Hope this gives you a few ideas.
Best Regards,
Sigrid
------------------------------
Sigrid Kok
PSE | Winshuttle North America
------------------------------