title: __declspec(dllexport) ::vector<std::string>
body: <p>I've been trying to work out how to return an array of strings from a c++ dll to a c# application but am stuck on how to do this or find an article at a very basic level.</p>
  
  <p>Suppose I have the code below.  How do I fix the bolded line:</p>
  
  <pre><code>extern "C" {
      __declspec(dllexport) int GetANumber();
  
  //unsure on this line:
      **__declspec(dllexport) ::vector&lt;std::string&gt; ListDevices();**
  
  }
  
  extern::vector&lt;std::string&gt; GetStrings()
  {
      vector&lt;string&gt; seqs;
      return seqs;
  }
  
  extern int GetANumber()
  {
      return 27;
  }
  </code></pre>
  
  <p>thanks</p>
  
  <p>Matt</p>