title: How to create an array in a structure that I need to get a pointer?
body: <p>I need to create an array inside a structure for the purpose of connecting to an embedded device. As such we using pointers to both the structure and it's internal fields...I tried the code below but should i just create 100 ints and be done??</p>
  
  <pre><code>[StructLayout( LayoutKind.Sequential )]
  public struct HRTF
  {
      UInt32 PPP;
      [MarshalAs(UnmanagedType.ByValArray, SizeConst = 100)]
      UInt32[] taps;
      . . . 
  }
  
  . . . 
  
  HRTF effects = new HRTF();
  
  /* --- ERROR cannot get address of, Sizeof ect ..to unmanaged typE 'HRTF' */
  int offset = ((int)&amp;effects.taps - startOffset) / 4; 
  int length = sizeof(HRTF) / 4;
  </code></pre>