0
Existe-t-il un contrôle dans uwp qui peut formater une chaîne json plus lisible?Contrôle de chaîne json au format dans uwp
Je veux dire si j'ai une chaîne comme
Et je veux un contrôle pour formater comme
Existe-t-il un contrôle dans uwp qui peut formater une chaîne json plus lisible?Contrôle de chaîne json au format dans uwp
Je veux dire si j'ai une chaîne comme
Et je veux un contrôle pour formater comme
Vous pouvez analyser la chaîne. Insérez une nouvelle ligne dans et x:Bind
cette méthode pour TextBlock.Text
:
private string ParseString(string jsonString)
{
return jsonString.Replace(",", ",\n").Replace("{", "{\n").Replace("}", "\n}");
}
Hmm ...... cela fonctionne, bien sûr. Mais je veux un contrôle comme https://www.bejson.com/ – Vincent