mIRC has an option to auto-cancel away states upon activity.

As for how to stop that from occuring with auto-op/voice.. Are you using the in-built auto-stuff or is it a scripted solution you are using?