Added some safeguards to throw an exception on invalid usage

A DriverException when invalid form actions are attempted on an element
is better than a fatal error.