added startshow and endshow functions