Error in Generated Form Code