Modified Alert Dialog and more code.