Parsing a JSON data into Javascript.

vishalneeraj-24503
Posted by vishalneeraj-24503 under JavaScript category on | Points: 40 | Views : 366
<script type="text/javascript"> 
function Parse_JSON_Data()
{
var JSON_Obj =
{
"Emp_Name": "Vishal Neeraj",
"Address": "Pune",
"Age": 30,
"Contact": "1234567890",
"Mail": "abc@yzz.com"
};
alert(JSON_Obj.Emp_Name);
alert(JSON_Obj.Address);
alert(JSON_Obj.Age);
alert(JSON_Obj.Contact);
alert(JSON_Obj.Mail);
}
</script>

<asp:Button ID="btn_parse" runat="server" OnClientClick ="Parse_JSON_Data();" Text="Parse" />

Comments or Responses

Login to post response