title: Concat two json strings in c#
body: <p>Let's say I have two JSON strings to start:
  (example from json.net)</p>
  
  <pre><code>string json1 = @"{
    'Name': 'Bad Boys',
    'ReleaseDate': '1995-4-7T00:00:00',
    'Genres': [
      'Action',
      'Comedy'
    ]
  }";
  
  and 
  
  string json2 = @"{
    'Name': 'Good Ol Boys',
    'ReleaseDate': '2995-4-7T00:00:00',
    'Genres': [
      'Action',
      'None'
    ]
  }";
  </code></pre>
  
  <p>What is the way to concatenate these two json strings into one json string? I've looked at a few different items here, and they don't fit the bill, primarily because they MERGE the two objects into one - I haven't seen a whole lot that just gives me two objects in one string. I found <a href="http://www.c-sharpcorner.com/forums/how-can-we-merge-two-json-strings" rel="nofollow noreferrer">this answer</a>, but it's for javascript, not C#. It is, however, close to what I want. </p>
  
  <p>The answer marked as correct for a <a href="https://stackoverflow.com/questions/21160337/how-can-i-merge-two-jobject">similar question</a> contains no explanation, nor enough code to provide the proper context for me to make sense out of it. And it's closer to what I'm looking to do, because it has the "data" element in it...whereas the answer with the greater number of votes merges and in some way overwrites one of my objects, leaving me with one, instead of two. </p>
  
  <p>I'm not ready to deserialize the string just yet, as I don't know how many objects I will get in advance. In other words, I want to put all the json object strings into one big string, then I can deserialize the whole string all at once. </p>
  
  <p>How do I do that?</p>
  
  <p><strong>EDIT</strong></p>
  
  <p>Turns out that I was asking how to concat two <em>arrays</em>, which is not the same thing at all. So my question was wrong. <a href="https://stackoverflow.com/a/21161350/3845390">This answer</a> is an answer to the question I referenced above. What I ended up doing is deserializing each array, then doing the <code>AddRange(d2.data)</code> method, and reserializing so that I could then deserialize the whole thing into one big JSON object. Which I then use elsewhere. </p>
  
  <p>And another thing - C# thinks of strings as strings, but even though JSON objects are technically strings, they're really not, which was part of my confusion. I also did not understand how JSON objects work, in terms of what is an array and what is a string...I had seen some answer on SO that basically said to make sure you understand what objects are in JSON, etc. Anyway...problem solved. </p>