×Welcome aboard! We are happy you are here and wish you good net-raft!



Together We Can Simplify The World

the current number of solutions:  2379
.htaccess (1x)    AJAX (13x)    ANGULARJS (161x)    ASP (1x)    ASP.NET (6x)    BACKBONE.JS (47x)    BOOTSTRAP (12x)    C# (226x)    COFFEESCRIPT (28x)    CSS (71x)    HTML (47x)    JADE (34x)    JAVA (51x)    JAVASCRIPT (432x)    JQUERY (395x)    JQUERY MOBILE (5x)    JSON (5x)    LARAVEL (27x)    MYSQL (9x)    NODEJS (162x)    ORACLE SQL (19x)    PERL (2x)    PHP (302x)    PYTHON (10x)    REACT (62x)    RUBY (25x)    RUBY ON RAILS (1x)    SHELL (2x)    SQL (90x)    SQL SERVER (3x)    TYPESCRIPT (51x)    VB.NET (33x)    W3.CSS (6x)    W3.JS (40x)    
join us

click to create your account

json string c#

(c# json string )

- C#

 viewed 45

Comment:
C#

0

var data = "your json string";
JavaScriptSerializer jss = new JavaScriptSerializer();
var d = jss.Deserialize<dynamic>(data);
string myvalue = d["your_key"];
return myvalue;

     

created: 6 months ago

The power of the user (%)

36%

Do you know a little more effective code ? Feel free to optimize ...


Comment:
C#

0

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>
<script runat="server">
protected void Page_Load(object sender, EventArgs e)
{

Response.Write(DisplayData());

}
</script>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
</head>
<body>
<form id="form1" runat="server">
</form>
</body>
</html>

// Default.aspx.cs
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.Services;
using System.Web.Script.Serialization;

public partial class _Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{

}
[WebMethod]
public static string DisplayData()
{
var data = "['Javascript', 'jQuery', 'Node.js', 'Angularjs']";
JavaScriptSerializer jss = new JavaScriptSerializer();
var d = jss.Deserialize<dynamic>(data);
string myvalue = d[2];

return myvalue;
}
}

     

created: 6 months ago

The power of the user (%)

49%

Do you know a little more effective code ? Feel free to optimize ...


haven't you found what you're looking for ?
Write us your question ...
Login is not needed.


The most helpful C# solutions
Likes Solution Technology
719 detect ie C#C#
148 Get real client ip address using C# ?C#
135 get real user country C#C#
106 how to initialize a connection to mysql database using C# ?C#
106 get hostname using C#C#
44 get username using C#C#
42 get real user country code C#C#
39 how to detect the type of a browser using C# in asp.net ?C#
32 How to detect monitor or notebook using C# ?C#
28 get real user city C#C#
Check out all of C# ...
The most viewed C# solutions by country
Solution Country
Get real client latitude and longitude using C# ?Cinque Terre
How to get the latitude and longitude from ip address using C# in asp.net ?Cinque Terre
get current url using C#Cinque Terre
Get real client latitude and longitude using C# ?Cinque Terre
Get real client latitude and longitude using C# ?Cinque Terre
check if cookie exists c#Cinque Terre
get current url using C#Cinque Terre
Get real client latitude and longitude using C# ?Cinque Terre
how do I connect to mysql database using C# ?Cinque Terre
How to get the region name from ip address using C# in asp.net ?Cinque Terre