K
K
krslnkv2019-02-05 21:50:01
JSON
krslnkv, 2019-02-05 21:50:01

How to fill DataGrid in WPF application using JSON and ObservableCollection?

Now I have a php script that generates JSON from a database. Further, all this must be transferred to a desktop application written in C #. It is planned to use a DataGrid for display, filling it through an ObservableCollection. The question is how to do it? Do you need the file itself for this, or is it enough to access the script via GET? Also interested in how to convert JSON to DataGrid.
I am also interested in the justification of such a decision, I plan to create a website for displaying information and a C # application for editing, adding, deleting.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
L
LiptonOlolo, 2019-02-06
@LiptonOlolo

1. "Do you need the file itself for this, or is it enough to access the script via GET?" - what prevents you from taking a JSON response from the server and making a model (s / s) for it and working not with JSON, but with ordinary classes?
2. How to convert JSON to DataGrid - no way (see point 1).
Regarding "How to Fill" - MVVM

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question