Latest Update with help from c0d3d. Script now running with input from widget