Repaired the Run function in Application.cpp