Tech
Forums
Jobs
Books
Events
Interviews
Live
More
Learn
Training
Career
Members
Videos
News
Blogs
Login
Sign Up
Ask Question
1
Reply
How to show deserialized Json as a list (dgv or listview)
ker ko
Apr 29 2015 8:16 AM
402
Reply
Hi guys,
I need help to display some json values in a list. I have absolutly no idea how to realize that. Could someone give me a Code-Example please.
At first my classes:
class
pulp
{
public
string
data {
get
;
set
; }
public
List<yelpi> yelpihi {
get
;
set
; }
}
class
yelpi
{
public
string
isi {
get
;
set
; }
public
double
inc {
get
;
set
; }
public
double
kal {
get
;
set
; }
public
string
mano {
get
;
set
; }
public
double
jet {
get
;
set
; }
public
double
polu {
get
;
set
; }
}
private
void
button3_Click(
object
sender, EventArgs e)
{
pulp jD =
new
JavaScriptSerializer().Deserialize<pulp>(am);
// "am" is the json-code which is going to deserialized
foreach
(
var
temp
in
jD.yelpihi)
{
// if I would display the code with MessageBox for example it would look like this:
/*isi : "Value 1"
inc : "Value 2"
kal : "Value 3"
mano : "Value 4"
jet : "Value 5"
polu : "Value 6" */
}
}
It would be very nice if some could "show" me how to implement and show this with datagridview, listviews or something like that.
Sincerely
K.K
Upload Source Code
Select only zip and rar file.
Post
Reset
Cancel
Answers (
1
)
Next Recommended Forum
How to Convert .HTML Extension to .ASPX Extension through c#
Why should everyone check this out and so