On-line process control in pharmaceutical industry