Dialogue box input fix
Inprogress build function

-Added lots of functionailty to the build function, not done yet.
-small bug fixes, error checks.