partially working generic form