Opena nd close editor functions added