In insurance risk theory, dividend and aggregate claim amount are of great research interest as they represent the insurance company's payments to its shareholders and policyholders, respectively. Since the analyses of these two quantities are performed separately in the literature, the companion paper by Cheung et al. generalised the Gerber-Shiu expected discounted penalty function by further incorporating the moments of the aggregate discounted claims until ruin and the discounted dividends until ruin. While Cheung et al. considered the compound Poisson model with a dividend barrier in which ruin occurs almost surely, the present paper looks at this generalised Gerber-Shiu function under a threshold dividend strategy where the insurer has a positive survival probability. Because the Gerber-Shiu function is only defined for sample paths leading to ruin, we will additionally study the joint moments of the aggregate discounted claims and the discounted dividends without ruin occurring. Some explicit formulas are derived when the individual claim distribution follows a combination of exponentials. Numerical illustrations involving the correlation between aggregate discounted claims and discounted dividends are given. For the case where ruin occurs, we additionally compute the correlations between the time of ruin and the above two quantities.