To calculate your return you simply link the return between withdrawal dates. That is, you calculate your return each time there is a cash flow to or from your account, and then start the next period with the new balance. Then you just link the returns to arrive at the total return for the whole period.
For example, say you start with 100K, on a certain date you have 120K in the account and you withdraw 40K. At a later date your account reaches 90K and you withdraw another 30K. So your total return over the whole period would be as follows:
Period 1: you started with 100K and before withdrawal reached 120K, so your return for the period is 120/100-1=20%.
Period 2: you had 120K, but took out 40K so your staring balance is 80K, and your ending balance before withdrawal is 90K so the return for this period is 90/80-1=12.5%
Total return for the 2 periods combined is (1.2*1.125)-1=35%.