A method for use in an electronic device, the method comprising: receiving a user input for inputting text data using a keypad while a message application is executed; displaying , on an input message display area of a display screen of the message application through a display of the electronic device, a first layer comprising a message content including the text data; displaying , on the input message display area of the display , a second layer for hiding at least a portion of the text data before transmitting a message including information on the first layer and information associated with the second layer; generating the message including information on the first layer and information associated with the second layer; and transmitting the generated message including information on the first layer and information associated with the second layer to a counterpart electronic device using a communication system , wherein the second layer is displayed to have an adjusted transparency to hide the at least a portion of the text data on the first layer; and wherein the generated message including information on the first layer and information associated with the second layer is configured to: enable displaying of the message on the counterpart electronic device, with the at least a portion of the text data being hidden by the second layer so that the at least a portion of the text data is unreadable, and enable revealing of the at least a portion of the text data of the first layer when a touch gesture on the second layer is sensed at the counterpart electronic device. receiving a user input for inputting text data using a keypad while a message application is executed; displaying , on an input message display area of a display screen of the message application through a display of the electronic device, a first layer comprising a message content including the text data; displaying , on the input message display area of the display , a second layer for hiding at least a portion of the text data before transmitting a message including information on the first layer and information associated with the second layer; generating the message including information on the first layer and information associated with the second layer; and transmitting the generated message including information on the first layer and information associated with the second layer to a counterpart electronic device using a communication system , wherein the second layer is displayed to have an adjusted transparency to hide the at least a portion of the text data on the first layer; and wherein the generated message including information on the first layer and information associated with the second layer is configured to: enable displaying of the message on the counterpart electronic device, with the at least a portion of the text data being hidden by the second layer so that the at least a portion of the text data is unreadable, and enable revealing of the at least a portion of the text data of the first layer when a touch gesture on the second layer is sensed at the counterpart electronic device. enable displaying of the message on the counterpart electronic device, with the at least a portion of the text data being hidden by the second layer so that the at least a portion of the text data is unreadable, and enable revealing of the at least a portion of the text data of the first layer when a touch gesture on the second layer is sensed at the counterpart electronic device. <EOS>