Can you exercise the out-of-the-money long leg of my spread position only if my in-the-money short leg is assigned?

No. There is no provision for issuing conditional exercise instructions to the OCC. The OCC determines the assignment of options based upon a random process which is initiated only after the deadline for submitting all exercise instructions has ended. In order to avoid the delivery of a long or short underlying stock position when only the short leg of an option spread is in-the-money at expiration, the account holder would need to either close out that short position or consider exercising an at-the-money long option.

Additional Information

Powered by IBot
What happens to my options spread at expiration?
How can I permanently prevent option positions from being exercised?
Will the long leg of an option spread be automatically exercised at expiration if the short is assigned?
Is it possible for a short option which is in-the-money not to be assigned?