Modified the way how a parent is selected on UpdateTextarea function.