This post has been so helpful and I really appreciate you posting this. I am wondering if someone could help just a bit. I am using the example from @mkeys and it is working. However in my use case I need the form to create the custom post type post as well as creating a new user. Can this function be altered to do both at the same time or do I need to create a generate post function for the same form and then add each field individually?
Thank you for looking and please help!