How to compensate gain and offset errors
If you have a linear circuit where Vout = f(Vin) and f(0) is ideally 0, it's easy, just null the input offset with 0V applied and apply something close to full scale and adjust the gain. No iterations required. 

For more complex situations where f is nonlinear and/or f(0) is not zero you may need to adjust the gain and offset both before and after the nonlinearity and/or you may have to iterate the adjustments.  

Ideally you want to minimize the interaction of the adjustments, to do that you have to analyze where the errors are coming from and adjust them appropriately. For example, take a simple signal conditioner that produces 4mA out for -10mV in and 20mA for +90mV in. If most of the offset error is in the front end (before gain) you can adjust out the offset there. So you might apply 0mV and adjust the offset (applied before the gain adjust) to get 5.6mA at the output. Then apply +90mV and adjust the gain to get 20mA. However if the gain has affected the zero a bit you may have to iterate a few times to get the adjustment accurate enough. 

Similarly, if the offset is more a result of tolerance of resistors in the output (say you use a zero-drift op-amp but compromise by using cheap 1% resistors rather than fancy ones) you may do better to apply -10mV and adjust for 4mA then +90mV and adjust for 20mA, repeat until both are within tolerance. 

If there is a nonlinearity in your circuit (perhaps you are linearizing a sensor) you may need more adjustments, since an error before a nonlinearity will lead to a error in the curve if you adjust it by fiddling the gain after then nonlinearity, and vice versa. 

Some of this becomes moot if you digitize the signals and manipulate them in the digital domain, but you still may have to worry about accuracy at the DAC and the ADC in a similar fashion.