Charge sharing between pixels is a significant concern in X-ray spectroscopy detectors based on monolithic arrays of Silicon Drift Detectors (SDDs) when a photon is absorbed near a pixel edge. Traditional mechanical collimation mitigates charge sharing but decreases the active area of the detector. This is particularly true for small-pixel detectors, where the mechanical collimator shields a significant portion of the active area and, moreover, becomes quite complex to be manufactured for small apertures. In this work, we carry out a study of charge sharing in SDDs and introduce active collimation as an alternative to mechanical collimation, leveraging key parameters of signals at the output of the charge sensitive amplifier (CSA), to identify charge-sharing events occurring within a defined coincidence window in neighboring pixels. To validate the technique, we first conducted a quantitative assessment of the impact of charge sharing on a 16-element monolithic SDD module with 2-mm-side square pixels using a focused pulsed laser. We then tested an active collimation algorithm on this detector configuration during a spectroscopic measurement with an uncollimated 55 Fe source, demonstrating its capability in recovering charge-sharing events and reconstructing them as Mn-Kpeak events. This active collimation approach, in contrast to mechanical collimation, not only enhances the effective active area while achieving a substantial reduction in the background continuum of the spectrum, but also recovers information inevitably lost in uncollimated detectors due to intrinsic charge sharing effects.